html, body {
    background: #f5f6f8;
    color: #1d232a;
    font-family: Inter, "Segoe UI", Arial, sans-serif;
    height: 100%;
    overflow: hidden;
}

a, .btn-link {
    color: #006bb7;
}

.btn-primary {
    color: #fff;
    background-color: #1b6ec2;
    border-color: #1861ac;
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

.content {
    flex: 1 1 auto;
    min-height: 0;
    overflow: hidden;
    padding-top: 1.1rem;
}

h1 {
    font-size: 1.6rem;
    margin: 0;
}

h2 {
    font-size: 1.1rem;
    margin: 0;
}

p {
    margin-bottom: 0;
}

.page-header,
.sessions-toolbar,
.chat-header,
.composer-actions {
    align-items: center;
    display: flex;
    gap: 1rem;
    justify-content: space-between;
}

.page-header {
    margin-bottom: 1rem;
}

.management-page {
    display: flex;
    flex-direction: column;
    height: 100%;
    min-height: 0;
    overflow: hidden;
}

.management-page > .table-shell {
    flex: 1 1 auto;
    min-height: 0;
}

.management-page .table {
    margin-bottom: 0;
}

.management-page thead th {
    background: #fff;
    position: sticky;
    top: 0;
    z-index: 2;
}

.button-row {
    align-items: center;
    display: flex;
    gap: 0.5rem;
}

.skill-path {
    display: block;
    max-width: 28rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.codex-auth-page {
    overflow: auto;
}

.codex-auth-grid {
    display: grid;
    gap: 1rem;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}

.codex-auth-panel {
    background: #fff;
    border: 1px solid #d8dde3;
    border-radius: 8px;
    display: grid;
    gap: 1rem;
    min-width: 0;
    padding: 1rem;
}

.detail-list {
    display: grid;
    gap: 0.65rem 1rem;
    grid-template-columns: 9rem minmax(0, 1fr);
    margin: 0;
}

.detail-list dt {
    color: #68717d;
    font-size: 0.82rem;
    font-weight: 700;
}

.detail-list dd {
    margin: 0;
    min-width: 0;
}

.detail-list code,
.codex-auth-url code {
    overflow-wrap: anywhere;
}

.device-code {
    background: #111827;
    border-radius: 8px;
    color: #ffffff;
    font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
    font-size: 2rem;
    font-weight: 800;
    letter-spacing: 0;
    padding: 1rem;
    text-align: center;
}

.codex-auth-error {
    background: #fff5f5;
    border: 1px solid #f1c0c0;
    border-radius: 6px;
    color: #8a1f1f;
    margin: 0;
    max-height: 14rem;
    overflow: auto;
    padding: 0.75rem;
    white-space: pre-wrap;
}

.codex-auth-url {
    color: #68717d;
    font-size: 0.85rem;
}

.sessions-page {
    display: grid;
    gap: 1rem;
    grid-template-rows: auto auto minmax(0, 1fr);
    height: 100%;
    min-height: 0;
    overflow: hidden;
}

.session-landing,
.session-detail-page {
    height: 100%;
    min-height: 0;
    overflow: hidden;
}

.session-landing {
    align-content: center;
    display: grid;
    justify-items: center;
    text-align: center;
}

.session-landing p {
    color: #68717d;
    margin-top: 0.5rem;
}

.session-detail-page {
    display: grid;
    gap: 0.75rem;
    grid-template-rows: auto auto minmax(0, 1fr);
    position: relative;
}

.session-detail-page > .page-alert {
    left: 0;
    margin: 0;
    position: absolute;
    right: 0;
    top: 0;
    z-index: 30;
}

.page-header p,
.sessions-toolbar p,
.chat-header p {
    color: #68717d;
    font-size: 0.9rem;
    margin-top: 0.25rem;
}

.table-shell,
.thread-pane,
.chat-pane {
    background: #fff;
    border: 1px solid #d8dde3;
    border-radius: 8px;
}

.table-shell {
    overflow: auto;
}

.empty-cell,
.empty-state {
    color: #68717d;
    padding: 1rem;
    text-align: center;
}

.session-grid {
    display: grid;
    gap: 1rem;
    grid-row: 3;
    grid-template-columns: minmax(260px, 32%) minmax(0, 1fr);
    min-height: 0;
    overflow: hidden;
}

.thread-pane {
    min-height: 0;
    overflow: auto;
    padding: 0.5rem;
}

.thread-item {
    background: transparent;
    border: 1px solid transparent;
    border-radius: 6px;
    color: inherit;
    display: grid;
    gap: 0.2rem;
    margin-bottom: 0.35rem;
    padding: 0.75rem;
    text-align: left;
    width: 100%;
}

.thread-item:hover,
.thread-item.selected {
    background: #eef6f3;
    border-color: #b8d8cd;
}

.thread-item.busy {
    border-color: #9ec5fe;
}

.thread-title {
    font-weight: 650;
}

.thread-meta,
.thread-status,
.message-meta {
    color: #68717d;
    font-size: 0.78rem;
}

.thread-status {
    align-items: center;
    display: inline-flex;
    gap: 0.35rem;
}

.busy-dot {
    animation: busyPulse 900ms ease-in-out infinite;
    background: #1b6ec2;
    border-radius: 999px;
    display: inline-block;
    height: 0.45rem;
    width: 0.45rem;
}

@keyframes busyPulse {
    0%, 100% {
        opacity: 0.35;
        transform: scale(0.85);
    }

    50% {
        opacity: 1;
        transform: scale(1);
    }
}

@media (prefers-reduced-motion: reduce) {
    .busy-dot {
        animation: none;
    }
}

.chat-pane {
    display: grid;
    grid-template-rows: auto minmax(300px, 1fr) auto;
    min-height: 0;
    min-width: 0;
    overflow: hidden;
}

.chat-header {
    border-bottom: 1px solid #e5e8ec;
    padding: 1rem;
}

.chat-header-actions {
    align-items: center;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: flex-end;
}

.session-detail-page > .chat-header,
.detail-tabs,
.info-pane,
.turns-pane,
.queue-pane,
.settings-pane,
.todos-pane,
.files-pane,
.attachments-pane,
.changes-pane,
.commits-pane {
    background: #fff;
    border: 1px solid #d8dde3;
    border-radius: 8px;
}

.session-detail-page > .chat-header {
    border-bottom: 1px solid #d8dde3;
}

.detail-tabs {
    display: flex;
    gap: 0.25rem;
    overflow-x: auto;
    padding: 0.35rem;
}

.detail-tab {
    background: transparent;
    border: 1px solid transparent;
    border-radius: 6px;
    color: #52606d;
    flex: 0 0 auto;
    font-weight: 650;
    padding: 0.5rem 0.85rem;
}

.detail-tab:hover,
.detail-tab.active {
    background: #eef6f3;
    border-color: #b8d8cd;
    color: #1d232a;
}

.session-chat-pane {
    grid-template-rows: minmax(0, 1fr) auto;
}

.info-pane,
.turns-pane,
.queue-pane,
.settings-pane,
.todos-pane,
.files-pane,
.attachments-pane,
.changes-pane,
.commits-pane {
    display: grid;
    grid-template-rows: auto minmax(0, 1fr);
    min-height: 0;
    overflow: hidden;
}

.info-toolbar,
.turns-toolbar,
.queue-toolbar,
.settings-toolbar,
.todos-toolbar,
.files-toolbar,
.attachments-toolbar,
.changes-toolbar,
.commits-toolbar {
    align-items: flex-start;
    border-bottom: 1px solid #e5e8ec;
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    justify-content: space-between;
    padding: 1rem;
}

.info-toolbar p,
.turns-toolbar p,
.queue-toolbar p,
.settings-toolbar p,
.todos-toolbar p,
.files-toolbar p,
.attachments-toolbar p,
.changes-toolbar p,
.commits-toolbar p {
    color: #68717d;
    font-size: 0.9rem;
    margin-top: 0.25rem;
}

.todo-list,
.queue-list,
.turn-list,
.file-list,
.change-list {
    min-height: 0;
    overflow: auto;
    padding: 0.5rem;
}

.todo-item,
.queue-item,
.turn-item,
.file-item,
.change-item {
    align-items: center;
    border: 1px solid #e5e8ec;
    border-radius: 6px;
    display: flex;
    gap: 1rem;
    justify-content: space-between;
    margin-bottom: 0.45rem;
    padding: 0.7rem 0.8rem;
}

.change-item {
    align-items: flex-start;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto auto;
}

.queue-item {
    align-items: flex-start;
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
}

.queue-index {
    align-items: center;
    background: #eef6f3;
    border-radius: 4px;
    color: #17613a;
    display: inline-flex;
    font-size: 0.78rem;
    font-weight: 800;
    height: 1.75rem;
    justify-content: center;
    min-width: 1.75rem;
}

.queue-main {
    display: grid;
    gap: 0.35rem;
    min-width: 0;
}

.queue-prompt {
    overflow-wrap: anywhere;
    white-space: pre-wrap;
}

.queue-meta,
.queue-actions {
    align-items: center;
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.queue-meta {
    color: #68717d;
    font-size: 0.78rem;
}

.files-toolbar-actions,
.changes-toolbar-actions,
.file-editor-actions,
.file-rename,
.file-create {
    align-items: center;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.files-toolbar-actions {
    flex: 0 0 auto;
}

.changes-toolbar-actions {
    flex: 0 0 auto;
    justify-content: flex-end;
}

.changes-content {
    display: flex;
    flex-direction: column;
    min-height: 0;
    overflow: hidden;
}

.git-action-status {
    background: #f7f9fb;
    border-bottom: 1px solid #e5e8ec;
    color: #394653;
    font-size: 0.86rem;
    padding: 0.55rem 1rem;
}

.info-content {
    display: grid;
    gap: 0.75rem;
    min-height: 0;
    overflow: auto;
    padding: 0.75rem;
}

.settings-form {
    display: grid;
    gap: 0.85rem;
    max-width: 36rem;
    overflow: auto;
    padding: 1rem;
}

.settings-actions {
    display: flex;
    justify-content: flex-end;
}

.info-section {
    border: 1px solid #e5e8ec;
    border-radius: 6px;
    padding: 0.85rem;
}

.info-section h3 {
    font-size: 0.95rem;
    margin: 0 0 0.75rem;
}

.info-grid {
    display: grid;
    gap: 0.75rem;
    grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr));
    margin: 0;
}

.info-grid div,
.metric,
.turn-item {
    min-width: 0;
}

.info-grid dt,
.metric span,
.turn-meta,
.turn-usage {
    color: #68717d;
    font-size: 0.78rem;
}

.info-grid dd {
    font-weight: 650;
    margin: 0.15rem 0 0;
    overflow-wrap: anywhere;
}

.metric-grid {
    display: grid;
    gap: 0.65rem;
    grid-template-columns: repeat(auto-fit, minmax(10rem, 1fr));
}

.metric {
    background: #f7f9fb;
    border: 1px solid #e5e8ec;
    border-radius: 6px;
    display: grid;
    gap: 0.25rem;
    padding: 0.75rem;
}

.metric strong {
    font-size: 1.05rem;
}

.limits-page {
    display: grid;
    gap: 1rem;
    height: 100%;
    min-height: 0;
    overflow: auto;
    padding-bottom: 1rem;
}

.limits-summary {
    display: grid;
    gap: 0.65rem;
    grid-template-columns: repeat(auto-fit, minmax(11rem, 1fr));
}

.limits-account {
    display: grid;
    gap: 0.75rem;
}

.limits-account-header {
    align-items: flex-start;
    display: flex;
    gap: 1rem;
    justify-content: space-between;
}

.limits-account-header h2 {
    font-size: 1.05rem;
    margin: 0;
    text-transform: capitalize;
}

.limits-account-header p {
    color: #68717d;
    font-size: 0.86rem;
    margin-top: 0.2rem;
}

.limits-account-header span {
    background: #e8f3ef;
    border-radius: 999px;
    color: #276851;
    flex: 0 0 auto;
    font-size: 0.76rem;
    font-weight: 750;
    padding: 0.25rem 0.55rem;
}

.limits-grid {
    display: grid;
    gap: 0.75rem;
    grid-template-columns: repeat(auto-fit, minmax(18rem, 1fr));
}

.limit-bucket {
    background: #fff;
    border: 1px solid #d8dde3;
    border-radius: 8px;
    display: grid;
    gap: 0.85rem;
    padding: 1rem;
}

.limit-bucket-header {
    align-items: flex-start;
    display: flex;
    gap: 1rem;
    justify-content: space-between;
}

.limit-bucket-header h2 {
    font-size: 1rem;
    margin: 0;
}

.limit-bucket-header p,
.limit-window-meta {
    color: #68717d;
    font-size: 0.78rem;
}

.limit-bucket-header span {
    background: #eef2f6;
    border-radius: 999px;
    color: #52606d;
    flex: 0 0 auto;
    font-size: 0.72rem;
    font-weight: 700;
    padding: 0.2rem 0.5rem;
}

.limit-window-list {
    display: grid;
    gap: 0.85rem;
}

.limit-window {
    display: grid;
    gap: 0.4rem;
}

.limit-window-row,
.limit-window-meta {
    align-items: center;
    display: flex;
    gap: 1rem;
    justify-content: space-between;
}

.limit-window-row span {
    font-weight: 700;
}

.limit-bar {
    background: #e8edf2;
    border-radius: 999px;
    height: 0.55rem;
    overflow: hidden;
}

.limit-bar span {
    background: #5fb89b;
    display: block;
    height: 100%;
}

.turn-list {
    display: grid;
    gap: 0.5rem;
}

.turn-item {
    align-items: stretch;
    display: grid;
    gap: 0.65rem;
}

.turn-summary {
    align-items: flex-start;
    display: flex;
    gap: 1rem;
    justify-content: space-between;
    min-width: 0;
}

.turn-id {
    font-family: "SFMono-Regular", Consolas, monospace;
    font-weight: 650;
    overflow-wrap: anywhere;
}

.turn-meta,
.turn-usage {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem 0.8rem;
    margin-top: 0.2rem;
}

.turn-total {
    background: #eef6f3;
    border-radius: 4px;
    color: #17613a;
    flex: 0 0 auto;
    font-size: 0.78rem;
    font-weight: 700;
    padding: 0.25rem 0.45rem;
}

.turn-error {
    background: #fdf0ef;
    border: 1px solid #edb8b1;
    border-radius: 4px;
    color: #9c2b20;
    font-size: 0.82rem;
    overflow-wrap: anywhere;
    padding: 0.45rem 0.55rem;
}

.turn-checkpoint {
    align-items: center;
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
    justify-content: space-between;
}

.turn-checkpoint-meta {
    align-items: center;
    color: #68717d;
    display: flex;
    flex-wrap: wrap;
    font-size: 0.78rem;
    gap: 0.45rem;
}

.checkpoint-status {
    background: #eef1f4;
    border-radius: 4px;
    color: #394653;
    font-weight: 700;
    padding: 0.2rem 0.4rem;
    text-transform: capitalize;
}

.checkpoint-status.complete {
    background: #e8f5ee;
    color: #17613a;
}

.checkpoint-status.failed {
    background: #fdecea;
    color: #9c2b20;
}

.checkpoint-status.capturing {
    background: #edf4ff;
    color: #245ea8;
}

.checkpoint-status.unavailable {
    background: #f7f9fb;
    color: #68717d;
}

.turn-checkpoint-files {
    border: 1px solid #e5e8ec;
    border-radius: 6px;
    overflow: hidden;
}

.checkpoint-file {
    align-items: flex-start;
    border-bottom: 1px solid #e5e8ec;
    display: flex;
    gap: 1rem;
    justify-content: space-between;
    padding: 0.55rem 0.65rem;
}

.checkpoint-file:last-child {
    border-bottom: 0;
}

.commits-body {
    display: grid;
    gap: 0.75rem;
    grid-template-columns: minmax(18rem, 34%) minmax(0, 1fr);
    min-height: 0;
    overflow: hidden;
    padding: 0.75rem;
}

.commit-list,
.commit-detail {
    border: 1px solid #e5e8ec;
    border-radius: 6px;
    min-height: 0;
    overflow: auto;
}

.commit-list {
    padding: 0.5rem;
}

.commit-item {
    background: transparent;
    border: 1px solid transparent;
    border-radius: 6px;
    color: inherit;
    display: grid;
    gap: 0.2rem;
    margin-bottom: 0.35rem;
    padding: 0.7rem;
    text-align: left;
    width: 100%;
}

.commit-item:hover,
.commit-item.selected {
    background: #eef6f3;
    border-color: #b8d8cd;
}

.commit-title {
    font-weight: 650;
    overflow-wrap: anywhere;
}

.commit-meta,
.commit-message,
.commit-detail-header p {
    color: #68717d;
    font-size: 0.78rem;
}

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

.commit-detail {
    display: grid;
    grid-template-rows: auto auto minmax(0, 1fr);
    overflow: hidden;
}

.commit-detail-header,
.commit-file-header {
    align-items: flex-start;
    display: flex;
    gap: 1rem;
    justify-content: space-between;
    min-width: 0;
}

.commit-detail-header {
    border-bottom: 1px solid #e5e8ec;
    padding: 1rem;
}

.commit-detail-header > div,
.commit-file-header > div:first-child {
    min-width: 0;
}

.commit-detail-header span {
    color: #68717d;
    flex: 0 0 auto;
    font-size: 0.82rem;
}

.commit-detail-message {
    background: #f7f9fb;
    border-bottom: 1px solid #e5e8ec;
    font-family: "SFMono-Regular", Consolas, monospace;
    font-size: 0.82rem;
    margin: 0;
    overflow-wrap: anywhere;
    padding: 0.75rem 1rem;
    white-space: pre-wrap;
}

.commit-files {
    min-height: 0;
    overflow: auto;
    padding: 0.6rem;
}

.commit-file {
    border: 1px solid #e5e8ec;
    border-radius: 6px;
    margin-bottom: 0.6rem;
    overflow: hidden;
}

.commit-file-header {
    border-bottom: 1px solid #e5e8ec;
    padding: 0.65rem 0.75rem;
}

.commit-diff-columns {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}

.commit-diff-columns pre {
    background: #fbfcfd;
    font-family: "SFMono-Regular", Consolas, monospace;
    font-size: 0.78rem;
    margin: 0;
    min-height: 8rem;
    overflow: auto;
    padding: 0.75rem;
    white-space: pre;
}

.commit-diff-columns pre:first-child {
    border-right: 1px solid #e5e8ec;
}

.files-body {
    display: grid;
    gap: 0.75rem;
    grid-template-columns: minmax(16rem, 36%) minmax(0, 1fr);
    min-height: 0;
    overflow: hidden;
    padding: 0.75rem;
}

.file-browser,
.file-editor {
    border: 1px solid #e5e8ec;
    border-radius: 6px;
    display: grid;
    gap: 0.5rem;
    min-height: 0;
    overflow: hidden;
    padding: 0.6rem;
}

.file-browser {
    grid-template-rows: auto auto minmax(0, 1fr);
}

.file-editor {
    grid-template-rows: auto auto minmax(0, 1fr) auto;
}

.file-create .form-control {
    flex: 1 1 10rem;
    min-width: 0;
    width: auto;
}

.file-create .btn,
.file-upload-control {
    flex: 0 0 auto;
}

.file-upload-control input[type="file"] {
    max-width: 13rem;
}

.file-list {
    padding: 0;
}

.file-item {
    padding: 0.45rem;
}

.file-item.selected {
    background: #eef6f3;
    border-color: #b8d8cd;
}

.file-main {
    align-items: center;
    background: transparent;
    border: 0;
    color: inherit;
    display: flex;
    flex: 1 1 auto;
    gap: 0.5rem;
    min-width: 0;
    padding: 0;
    text-align: left;
}

.file-kind,
.file-size {
    color: #68717d;
    flex: 0 0 auto;
    font-size: 0.72rem;
    text-transform: uppercase;
}

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

.file-editor-header {
    align-items: flex-start;
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    justify-content: space-between;
    min-width: 0;
}

.file-editor-header > div {
    min-width: 0;
}

.file-editor-header h2 {
    overflow-wrap: anywhere;
}

.file-editor-header p {
    color: #68717d;
    font-size: 0.84rem;
    margin-top: 0.2rem;
}

.file-content-editor {
    font-family: "SFMono-Regular", Consolas, monospace;
    font-size: 0.84rem;
    height: 100%;
    min-height: 0;
    resize: none;
}

.change-status.included {
    background: #e8f5ee;
    color: #17613a;
}

.change-status.excluded {
    background: #eef1f4;
    color: #394653;
}

.todo-item {
    justify-content: flex-start;
}

.todo-item input {
    flex: 0 0 auto;
}

.todo-item.done .todo-message {
    color: #68717d;
    text-decoration: line-through;
}

.todo-message {
    font-weight: 650;
    overflow-wrap: anywhere;
}

.todo-state {
    color: #68717d;
    font-size: 0.78rem;
    margin-top: 0.15rem;
}

.change-path {
    font-family: "SFMono-Regular", Consolas, monospace;
    font-size: 0.86rem;
    overflow-wrap: anywhere;
}

.change-old-path {
    color: #68717d;
    font-family: "SFMono-Regular", Consolas, monospace;
    font-size: 0.74rem;
    margin-top: 0.2rem;
    overflow-wrap: anywhere;
}

.change-meta {
    align-items: center;
    display: flex;
    flex: 0 0 auto;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.change-actions {
    display: flex;
    flex: 0 0 auto;
    flex-wrap: wrap;
    gap: 0.4rem;
    justify-content: flex-end;
}

.change-status,
.change-additions,
.change-deletions {
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 700;
    padding: 0.2rem 0.4rem;
}

.change-status {
    background: #eef1f4;
    color: #394653;
}

.change-additions {
    background: #e8f5ee;
    color: #17613a;
}

.change-deletions {
    background: #fdecea;
    color: #9c2b20;
}

.transcript {
    min-height: 0;
    overflow: auto;
    padding: 1rem;
}

.message {
    border-left: 3px solid #c9d1d9;
    margin-bottom: 1rem;
    padding-left: 0.75rem;
}

.message.user {
    border-left-color: #2f6fbb;
}

.message.optimistic-message {
    opacity: 0.78;
}

.message.assistant {
    border-left-color: #2d8a62;
}

.message.system {
    border-left-color: #c35f2b;
}

.message.message {
    border-left-color: #2d8a62;
}

.message.commentary {
    border-left-color: #5c6f82;
}

.message.reasoning {
    border-left-color: #7a5aa6;
}

.message.toolcall {
    border-left-color: #c35f2b;
}

.message.approval {
    border-left-color: #9d6a1f;
}

.message.contextcompaction {
    border-left-color: #1b6ec2;
}

.message.contextclear {
    border-left-color: #1b6ec2;
}

.message.error {
    background: #fff7f6;
    border-left-color: #c23b2e;
    padding-bottom: 0.35rem;
    padding-top: 0.35rem;
}

.message.error .message-meta {
    color: #9c2b20;
}

.message pre {
    font-family: "SFMono-Regular", Consolas, monospace;
    font-size: 0.86rem;
    margin: 0.2rem 0 0;
    white-space: pre-wrap;
}

.message-detail {
    background: #f1f3f5;
    border-radius: 4px;
    display: block;
    font-size: 0.78rem;
    margin-top: 0.35rem;
    overflow-wrap: anywhere;
    padding: 0.35rem 0.5rem;
}

.tool-call-card {
    align-items: flex-start;
    background: #f7f9fb;
    border: 1px solid #e5e8ec;
    border-radius: 6px;
    display: flex;
    gap: 0.65rem;
    margin-top: 0.35rem;
    padding: 0.65rem 0.75rem;
}

.tool-call-card > i {
    align-items: center;
    background: #eef1f4;
    border-radius: 4px;
    color: #394653;
    display: inline-flex;
    flex: 0 0 auto;
    height: 1.75rem;
    justify-content: center;
    width: 1.75rem;
}

.tool-call-title {
    font-weight: 650;
}

.tool-call-detail {
    color: #52606d;
    font-size: 0.84rem;
    margin-top: 0.1rem;
    overflow-wrap: anywhere;
}

.tool-call-meta {
    color: #68717d;
    display: flex;
    flex-wrap: wrap;
    font-size: 0.76rem;
    gap: 0.45rem;
    margin-top: 0.25rem;
}

.approval-card {
    background: #fff8ed;
    border: 1px solid #e8cfa4;
    border-radius: 6px;
    display: grid;
    gap: 0.5rem;
    margin-top: 0.35rem;
    padding: 0.75rem;
}

.approval-card.approved {
    background: #edf8f2;
    border-color: #b8d8cd;
}

.approval-card.rejected,
.approval-card.failed {
    background: #fdf0ef;
    border-color: #edb8b1;
}

.approval-card-header {
    align-items: center;
    display: flex;
    gap: 0.75rem;
    justify-content: space-between;
}

.approval-card-header > div:first-child {
    align-items: center;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.approval-card-header span {
    background: #f1e2c8;
    border-radius: 4px;
    color: #68450d;
    font-size: 0.72rem;
    font-weight: 700;
    padding: 0.2rem 0.4rem;
    text-transform: uppercase;
}

.approval-card.approved .approval-card-header span {
    background: #d9efe4;
    color: #17613a;
}

.approval-card.rejected .approval-card-header span,
.approval-card.failed .approval-card-header span {
    background: #f7d8d4;
    color: #9c2b20;
}

.approval-actions {
    display: flex;
    flex: 0 0 auto;
    gap: 0.5rem;
}

.approval-path {
    color: #68717d;
    font-family: "SFMono-Regular", Consolas, monospace;
    font-size: 0.76rem;
    overflow-wrap: anywhere;
}

.message-attachments {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    margin-top: 0.5rem;
}

.message-attachment {
    align-items: center;
    background: #f7f9fb;
    border: 1px solid #d8dde3;
    border-radius: 6px;
    color: #1d232a;
    display: inline-flex;
    gap: 0.45rem;
    max-width: 100%;
    padding: 0.35rem 0.55rem;
    text-decoration: none;
}

.message-attachment:hover {
    background: #eef6f3;
    border-color: #b8d8cd;
}

.attachments-list {
    display: grid;
    gap: 0.75rem;
    overflow: auto;
    padding: 1rem;
}

.attachment-row {
    align-items: center;
    border: 1px solid #d8dde3;
    border-radius: 6px;
    display: grid;
    gap: 0.75rem;
    grid-template-columns: minmax(0, 1fr) auto;
    padding: 0.8rem;
}

.attachment-row-main {
    align-items: center;
    color: #1d232a;
    display: inline-flex;
    gap: 0.55rem;
    min-width: 0;
    text-decoration: none;
}

.attachment-row-main:hover .attachment-name {
    text-decoration: underline;
}

.attachment-row-meta {
    color: #68717d;
    display: flex;
    flex-wrap: wrap;
    font-size: 0.8rem;
    gap: 0.6rem;
    justify-content: flex-end;
}

.attachment-kind,
.attachment-size {
    color: #68717d;
    font-size: 0.72rem;
    text-transform: uppercase;
}

.attachment-name {
    max-width: 18rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.composer {
    border-top: 1px solid #e5e8ec;
    display: grid;
    gap: 0.75rem;
    padding: 1rem;
}

.attachment-tools {
    align-items: center;
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.url-attachment {
    display: flex;
    flex: 1 1 20rem;
    gap: 0.5rem;
    min-width: 0;
}

.url-attachment .form-control {
    min-width: 0;
}

.attachment-drafts {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
}

.attachment-draft {
    align-items: center;
    background: #eef1f4;
    border: 1px solid #d8dde3;
    border-radius: 6px;
    display: inline-flex;
    gap: 0.5rem;
    max-width: 100%;
    padding: 0.35rem 0.45rem 0.35rem 0.6rem;
}

.attachment-draft > span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.attachment-draft small {
    color: #68717d;
    flex: 0 0 auto;
}

.composer-actions {
    flex-wrap: wrap;
    justify-content: flex-end;
}

.composer-actions .form-select {
    max-width: 12rem;
}

.modal {
    display: block;
    inset: 0;
    position: fixed;
    z-index: 1060;
}

.modal-backdrop {
    z-index: 1050;
}

.modal-dialog {
    margin-bottom: 2rem;
    margin-top: 5rem;
}

.modal-content {
    max-height: calc(100vh - 7rem);
}

.modal-body {
    overflow: auto;
}

.modal-title {
    font-size: 1.1rem;
}

@media (max-width: 760px) {
    .content {
        padding-top: 0.75rem;
    }

    .session-grid {
        grid-template-columns: 1fr;
        grid-template-rows: minmax(9rem, 32%) minmax(0, 1fr);
    }

    .page-header,
    .sessions-toolbar,
    .chat-header {
        align-items: flex-start;
        flex-direction: column;
    }

    .files-body {
        grid-template-columns: 1fr;
        grid-template-rows: minmax(12rem, 40%) minmax(0, 1fr);
    }

    .change-item {
        grid-template-columns: 1fr;
    }

    .attachment-row {
        grid-template-columns: 1fr;
    }

    .attachment-row-meta {
        justify-content: flex-start;
    }

    .change-actions {
        justify-content: flex-start;
    }

    .commits-body,
    .commit-diff-columns {
        grid-template-columns: 1fr;
    }

    .commit-diff-columns pre:first-child {
        border-bottom: 1px solid #e5e8ec;
        border-right: 0;
    }

    .url-attachment {
        flex-basis: 100%;
    }
}

h1:focus {
    outline: none;
}

.valid.modified:not([type=checkbox]) {
    outline: 1px solid #26b050;
}

.invalid {
    outline: 1px solid #e50000;
}

.validation-message {
    color: #e50000;
}

.blazor-error-boundary {
    background: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTYiIGhlaWdodD0iNDkiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIG92ZXJmbG93PSJoaWRkZW4iPjxkZWZzPjxjbGlwUGF0aCBpZD0iY2xpcDAiPjxyZWN0IHg9IjIzNSIgeT0iNTEiIHdpZHRoPSI1NiIgaGVpZ2h0PSI0OSIvPjwvY2xpcFBhdGg+PC9kZWZzPjxnIGNsaXAtcGF0aD0idXJsKCNjbGlwMCkiIHRyYW5zZm9ybT0idHJhbnNsYXRlKC0yMzUgLTUxKSI+PHBhdGggZD0iTTI2My41MDYgNTFDMjY0LjcxNyA1MSAyNjUuODEzIDUxLjQ4MzcgMjY2LjYwNiA1Mi4yNjU4TDI2Ny4wNTIgNTIuNzk4NyAyNjcuNTM5IDUzLjYyODMgMjkwLjE4NSA5Mi4xODMxIDI5MC41NDUgOTIuNzk1IDI5MC42NTYgOTIuOTk2QzI5MC44NzcgOTMuNTEzIDI5MSA5NC4wODE1IDI5MSA5NC42NzgyIDI5MSA5Ny4wNjUxIDI4OS4wMzggOTkgMjg2LjYxNyA5OUwyNDAuMzgzIDk5QzIzNy45NjMgOTkgMjM2IDk3LjA2NTEgMjM2IDk0LjY3ODIgMjM2IDk0LjM3OTkgMjM2LjAzMSA5NC4wODg2IDIzNi4wODkgOTMuODA3MkwyMzYuMzM4IDkzLjAxNjIgMjM2Ljg1OCA5Mi4xMzE0IDI1OS40NzMgNTMuNjI5NCAyNTkuOTYxIDUyLjc5ODUgMjYwLjQwNyA1Mi4yNjU4QzI2MS4yIDUxLjQ4MzcgMjYyLjI5NiA1MSAyNjMuNTA2IDUxWk0yNjMuNTg2IDY2LjAxODNDMjYwLjczNyA2Ni4wMTgzIDI1OS4zMTMgNjcuMTI0NSAyNTkuMzEzIDY5LjMzNyAyNTkuMzEzIDY5LjYxMDIgMjU5LjMzMiA2OS44NjA4IDI1OS4zNzEgNzAuMDg4N0wyNjEuNzk1IDg0LjAxNjEgMjY1LjM4IDg0LjAxNjEgMjY3LjgyMSA2OS43NDc1QzI2Ny44NiA2OS43MzA5IDI2Ny44NzkgNjkuNTg3NyAyNjcuODc5IDY5LjMxNzkgMjY3Ljg3OSA2Ny4xMTgyIDI2Ni40NDggNjYuMDE4MyAyNjMuNTg2IDY2LjAxODNaTTI2My41NzYgODYuMDU0N0MyNjEuMDQ5IDg2LjA1NDcgMjU5Ljc4NiA4Ny4zMDA1IDI1OS43ODYgODkuNzkyMSAyNTkuNzg2IDkyLjI4MzcgMjYxLjA0OSA5My41Mjk1IDI2My41NzYgOTMuNTI5NSAyNjYuMTE2IDkzLjUyOTUgMjY3LjM4NyA5Mi4yODM3IDI2Ny4zODcgODkuNzkyMSAyNjcuMzg3IDg3LjMwMDUgMjY2LjExNiA4Ni4wNTQ3IDI2My41NzYgODYuMDU0N1oiIGZpbGw9IiNGRkU1MDAiIGZpbGwtcnVsZT0iZXZlbm9kZCIvPjwvZz48L3N2Zz4=) no-repeat 1rem/1.8rem, #b32121;
    padding: 1rem 1rem 1rem 3.7rem;
    color: white;
}

    .blazor-error-boundary::after {
        content: "An error has occurred."
    }

.darker-border-checkbox.form-check-input {
    border-color: #929292;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
    color: var(--bs-secondary-color);
    text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
    text-align: start;
}
