/* Hydra Touch — global Mini Hub. Quiet trigger, below modal sheets. */

#hydraTouchRoot {
  position: static;
}

#hydraTouchRoot.is-capturing,
#hydraTouchRoot.is-capturing * {
  visibility: hidden !important;
  pointer-events: none !important;
}

.hydra-touch-btn {
  position: fixed;
  z-index: calc(var(--z-mobile-sheet, 6200) - 60);
  left: max(16px, env(safe-area-inset-left, 0px));
  bottom: calc(var(--bottom-nav-height, 36px) + env(safe-area-inset-bottom, 0px) + 12px);
  width: 48px;
  height: 48px;
  min-width: 48px;
  min-height: 48px;
  padding: 0;
  margin: 0;
  border: 1px solid rgba(15, 23, 42, 0.12);
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 6px 16px rgba(15, 23, 42, 0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  opacity: 0.65;
  transition: opacity 280ms ease;
}

.hydra-touch-btn__dot {
  width: 14px;
  height: 14px;
  border-radius: 999px;
  background: #f97316;
}

#hydraTouchRoot.is-active .hydra-touch-btn {
  opacity: 1;
}

#hydraTouchRoot.is-open .hydra-touch-btn {
  display: none;
}

.hydra-touch-sheet {
  position: fixed;
  z-index: calc(var(--z-mobile-sheet, 6200) - 20);
  left: 0;
  right: 0;
  bottom: calc(var(--bottom-nav-height, 36px) + env(safe-area-inset-bottom, 0px));
  max-height: min(72vh, 640px);
  max-height: min(72dvh, 640px);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: #fff;
  border-radius: 22px 22px 0 0;
  box-shadow: 0 -12px 40px rgba(15, 23, 42, 0.16);
  padding: 14px 14px 12px;
  box-sizing: border-box;
}

.hydra-touch-sheet[hidden] {
  display: none !important;
}

.hydra-touch-sheet__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 2px;
  flex-shrink: 0;
}

.hydra-touch-sheet__meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-height: 28px;
  margin-bottom: 8px;
}

.hydra-touch-count {
  margin: 0;
  font-size: 13px;
  font-weight: 700;
  color: #64748b;
  font-variant-numeric: tabular-nums;
}

.hydra-touch-clear {
  border: 0;
  background: transparent;
  color: #b91c1c;
  font-size: 13px;
  font-weight: 700;
  min-height: 32px;
  padding: 0 2px;
  cursor: pointer;
}

.hydra-touch-sheet__title {
  margin: 0;
  font-size: 17px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #0f172a;
}

.hydra-touch-sheet__chrome {
  flex-shrink: 0;
}

.hydra-touch-sheet__close {
  width: 44px;
  height: 44px;
  border: 0;
  background: transparent;
  font-size: 22px;
  line-height: 1;
  color: #64748b;
  cursor: pointer;
}

.hydra-touch-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 10px;
}

.hydra-touch-actions .hydra-touch-primary,
.hydra-touch-actions .hydra-touch-secondary {
  min-height: 44px;
  border-radius: 14px;
  font-size: 16px;
  font-weight: 800;
  cursor: pointer;
}

.hydra-touch-primary {
  border: 0;
  color: #fff;
  background: #f97316;
}

.hydra-touch-secondary {
  border: 1px solid #e2e8f0;
  background: #fff;
  color: #0f172a;
}

.hydra-touch-primary:disabled,
.hydra-touch-secondary:disabled {
  opacity: 0.6;
}

.hydra-touch-list {
  overflow: auto;
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  touch-action: pan-y;
}

.hydra-touch-empty {
  margin: 8px 2px 4px;
  color: #64748b;
  font-size: 14px;
  line-height: 1.4;
}

.hydra-touch-row {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  padding: 8px;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  background: #fff;
}

.hydra-touch-row--pending {
  background: #fff7ed;
  border-color: #fed7aa;
  grid-template-columns: 1fr;
}

.hydra-touch-thumb {
  width: 72px;
  height: 72px;
  border-radius: 12px;
  object-fit: cover;
  background: #f1f5f9;
}

.hydra-touch-row__title {
  margin: 0;
  font-size: 15px;
  font-weight: 800;
  color: #0f172a;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hydra-touch-row__meta {
  margin: 2px 0 6px;
  font-size: 12px;
  color: #64748b;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hydra-touch-row__actions {
  display: flex;
  gap: 6px;
  flex-wrap: nowrap;
}

.hydra-touch-row__actions button {
  min-height: 32px;
  padding: 0 8px;
  border: 0;
  background: transparent;
  color: #0f172a;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}

.hydra-touch-error {
  margin: 0 0 8px;
  color: #b91c1c;
  font-size: 13px;
  font-weight: 700;
}

.hydra-touch-viewer,
.hydra-touch-confirm {
  position: fixed;
  inset: 0;
  z-index: 9900;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: stretch;
  padding:
    max(12px, env(safe-area-inset-top, 0px))
    max(12px, env(safe-area-inset-right, 0px))
    max(12px, env(safe-area-inset-bottom, 0px))
    max(12px, env(safe-area-inset-left, 0px));
  box-sizing: border-box;
}

.hydra-touch-viewer {
  background: rgba(15, 23, 42, 0.88);
  touch-action: manipulation;
  height: 100%;
  height: 100dvh;
  max-height: 100dvh;
  overflow: hidden;
}

.hydra-touch-viewer[hidden],
.hydra-touch-confirm[hidden] {
  display: none !important;
}

.hydra-touch-viewer__stage {
  position: relative;
  z-index: 1;
  flex: 1 1 auto;
  min-height: 0;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: auto;
  -webkit-overflow-scrolling: touch;
  touch-action: pinch-zoom pan-x pan-y;
  padding: 4px 0;
  box-sizing: border-box;
}

.hydra-touch-viewer__stage img {
  display: block;
  width: auto;
  height: auto;
  max-width: min(960px, 100%);
  max-height: min(
    100%,
    calc(100dvh - env(safe-area-inset-top, 0px) - env(safe-area-inset-bottom, 0px) - 96px)
  );
  object-fit: contain;
  object-position: center;
  border-radius: 12px;
  background: #0f172a;
  flex-shrink: 0;
}

.hydra-touch-viewer__stage img.is-zoomed {
  max-width: none;
  max-height: none;
}

.hydra-touch-viewer__stage img.is-loading {
  opacity: 0.2;
}

.hydra-touch-viewer__loading {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  box-sizing: border-box;
  font-size: 14px;
  font-weight: 600;
  color: #e2e8f0;
  pointer-events: none;
}

.hydra-touch-viewer__loading[hidden] {
  display: none !important;
}

.hydra-touch-viewer__stage img.is-error {
  min-width: 120px;
  min-height: 80px;
  object-fit: contain;
}

.hydra-touch-viewer__unavailable {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 24px;
  box-sizing: border-box;
  text-align: center;
  color: #f8fafc;
  pointer-events: auto;
}

.hydra-touch-viewer__unavailable[hidden] {
  display: none !important;
}

.hydra-touch-viewer__unavailable p {
  margin: 0;
  font-size: 15px;
  font-weight: 600;
  max-width: 280px;
  line-height: 1.35;
}

.hydra-touch-viewer__thumbs {
  position: relative;
  z-index: 3;
  flex-shrink: 0;
  display: flex;
  flex-wrap: nowrap;
  gap: 8px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  padding: 8px 12px max(10px, env(safe-area-inset-bottom, 0px));
  box-sizing: border-box;
  max-height: 92px;
}

.hydra-touch-viewer__thumb {
  flex: 0 0 auto;
  border: 2px solid transparent;
  border-radius: 10px;
  padding: 0;
  background: rgba(15, 23, 42, 0.55);
  width: 56px;
  height: 56px;
  overflow: hidden;
  cursor: pointer;
}

.hydra-touch-viewer__thumb.is-active {
  border-color: #f97316;
}

.hydra-touch-viewer__thumb img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hydra-touch-viewer__thumb.is-unavailable {
  background: rgba(15, 23, 42, 0.85);
  cursor: pointer;
}

.hydra-touch-viewer__thumb.is-unavailable::after {
  content: "—";
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  font-size: 18px;
  font-weight: 700;
  color: #94a3b8;
}

.hydra-touch-artifacts__img.is-unavailable,
.hydra-touch-md-img img.is-unavailable,
.hydra-touch-thumb.is-unavailable {
  object-fit: none;
  background:
    linear-gradient(135deg, #e2e8f0 25%, transparent 25%) -8px 0/16px 16px,
    linear-gradient(225deg, #e2e8f0 25%, transparent 25%) -8px 0/16px 16px,
    linear-gradient(315deg, #e2e8f0 25%, transparent 25%) 0 0/16px 16px,
    linear-gradient(45deg, #e2e8f0 25%, transparent 25%) 0 0/16px 16px,
    #f1f5f9;
}

.hydra-touch-viewer__toolbar {
  position: relative;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  flex-shrink: 0;
  min-height: 44px;
  padding: 0 52px 6px;
  box-sizing: border-box;
}

.hydra-touch-viewer__tool {
  border: 1px solid rgba(255, 255, 255, 0.28);
  background: rgba(15, 23, 42, 0.55);
  color: #f8fafc;
  border-radius: 999px;
  min-height: 36px;
  padding: 0 14px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  touch-action: manipulation;
}

.hydra-touch-viewer__tool[aria-pressed="true"] {
  background: rgba(255, 255, 255, 0.94);
  color: #0f172a;
  border-color: transparent;
}

.hydra-touch-viewer__close {
  position: absolute;
  top: max(8px, env(safe-area-inset-top, 0px));
  right: max(8px, env(safe-area-inset-right, 0px));
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.94);
  color: #0f172a;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
}

.hydra-touch-confirm {
  z-index: 9960;
  background: rgba(15, 23, 42, 0.45);
}

.hydra-touch-confirm__card {
  width: min(360px, 100%);
  background: #fff;
  border-radius: 18px;
  padding: 16px;
  box-shadow: 0 16px 40px rgba(15, 23, 42, 0.2);
}

.hydra-touch-confirm__card p {
  margin: 0 0 14px;
  font-size: 16px;
  font-weight: 800;
  color: #0f172a;
}

.hydra-touch-confirm__actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

.hydra-touch-confirm__actions button {
  min-height: 44px;
  padding: 0 14px;
  border-radius: 12px;
  font-size: 15px;
  font-weight: 800;
  cursor: pointer;
}

.hydra-touch-confirm__cancel {
  border: 1px solid #e2e8f0;
  background: #fff;
  color: #0f172a;
}

.hydra-touch-danger {
  border: 0;
  background: #dc2626;
  color: #fff;
}

/* Tools shell is its own fixed layer (z-index 8000). Stay inside that layer,
   above the page and under in-shell modals (9000+). */
#hydraToolsShell > #hydraTouchRoot .hydra-touch-btn {
  z-index: 8900;
}

#hydraToolsShell > #hydraTouchRoot .hydra-touch-sheet {
  z-index: 8950;
}

#hydraToolsShell > #hydraTouchRoot .hydra-touch-composer {
  z-index: 8970;
}

#hydraToolsShell > #hydraTouchRoot .hydra-touch-result {
  z-index: 8980;
}

@media (max-width: 900px) {
  html.hydra-touch-open,
  body.hydra-touch-open {
    overflow: hidden;
  }

  html.hydra-touch-open #mobileOwnerBottomNav,
  body.hydra-touch-open #mobileOwnerBottomNav,
  html.hydra-touch-open .mobile-owner-bottom-nav,
  body.hydra-touch-open .mobile-owner-bottom-nav {
    visibility: hidden !important;
    pointer-events: none !important;
  }

  #hydraTouchRoot.is-open .hydra-touch-sheet {
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    max-height: none;
    height: 100dvh;
    border-radius: 0;
    box-shadow: none;
    z-index: var(--z-mobile-sheet, 6200);
    padding-top: max(10px, env(safe-area-inset-top, 0px));
    padding-bottom: max(12px, env(safe-area-inset-bottom, 0px));
    padding-left: max(14px, env(safe-area-inset-left, 0px));
    padding-right: max(14px, env(safe-area-inset-right, 0px));
  }

  #hydraTouchRoot.is-open .hydra-touch-sheet__chrome {
    position: sticky;
    top: 0;
    z-index: 3;
    margin: 0 -2px;
    padding: 0 2px 2px;
    background: #fff;
  }

  #hydraTouchRoot.is-open .hydra-touch-composer {
    z-index: calc(var(--z-mobile-sheet, 6200) + 40);
    align-items: stretch;
    padding: 0;
    background: rgba(15, 23, 42, 0.32);
  }

  #hydraTouchRoot.is-open .hydra-touch-result {
    z-index: calc(var(--z-mobile-sheet, 6200) + 40);
    align-items: flex-end;
    padding: 0;
    background: rgba(15, 23, 42, 0.32);
  }

  #hydraTouchRoot.is-open .hydra-touch-composer__card {
    width: 100%;
    max-height: 100dvh;
    margin: 0;
    border-radius: 0;
    padding-top: max(10px, env(safe-area-inset-top, 0px));
    padding-bottom: max(12px, env(safe-area-inset-bottom, 0px));
    padding-left: max(14px, env(safe-area-inset-left, 0px));
    padding-right: max(14px, env(safe-area-inset-right, 0px));
  }

  #hydraTouchRoot.is-open .hydra-touch-result__card {
    width: 100%;
    height: auto;
    max-height: min(82dvh, 720px);
    margin: 0;
    border-radius: 22px 22px 0 0;
    padding-top: 14px;
    padding-bottom: max(12px, env(safe-area-inset-bottom, 0px));
    padding-left: max(14px, env(safe-area-inset-left, 0px));
    padding-right: max(14px, env(safe-area-inset-right, 0px));
  }

  #hydraTouchRoot.is-open .hydra-touch-result__card .hydra-touch-sheet__head {
    position: sticky;
    top: 0;
    z-index: 2;
    background: #fff;
  }

  #hydraTouchRoot.is-open .hydra-touch-btn {
    bottom: calc(env(safe-area-inset-bottom, 0px) + 16px);
  }

  #hydraToolsShell > #hydraTouchRoot.is-open .hydra-touch-sheet {
    z-index: 8950;
  }

  #hydraToolsShell > #hydraTouchRoot.is-open .hydra-touch-composer,
  #hydraToolsShell > #hydraTouchRoot.is-open .hydra-touch-result {
    z-index: 8990;
  }

  #hydraTouchRoot.is-open .hydra-touch-pane[data-touch-pane="server"] {
    padding-bottom: 4px;
    scroll-padding-bottom: 8px;
  }

  #hydraTouchRoot.is-open .hydra-touch-artifacts {
    gap: 6px;
  }

  #hydraTouchRoot.is-open .hydra-touch-artifacts__cell,
  #hydraTouchRoot.is-open .hydra-touch-artifacts__item {
    width: 64px;
  }

  #hydraTouchRoot.is-open .hydra-touch-artifacts__img {
    width: 64px;
    height: 64px;
  }

  #hydraTouchRoot.is-open .hydra-touch-thumb {
    width: 64px;
    height: 64px;
  }

  #hydraTouchRoot.is-open .hydra-touch-row {
    grid-template-columns: 64px minmax(0, 1fr);
  }

  #hydraTouchRoot.is-open .hydra-touch-run__artifacts {
    font-size: 11px;
    color: #64748b;
    font-weight: 750;
  }
}

.hydra-touch-tabs {
  display: flex;
  flex-wrap: nowrap;
  flex-shrink: 0;
  gap: 4px;
  margin: 0 0 10px;
  padding: 3px;
  border-radius: 11px;
  background: #f1f5f9;
}

.hydra-touch-tab {
  flex: 1 1 0;
  min-width: 0;
  min-height: 44px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: #475569;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.15;
  white-space: nowrap;
  cursor: pointer;
  padding: 0 4px;
}

@media (max-width: 390px) {
  .hydra-touch-tabs {
    gap: 2px;
    padding: 2px;
  }

  .hydra-touch-tab {
    font-size: 11px;
    padding: 0 2px;
    letter-spacing: -0.02em;
  }
}

.hydra-touch-tab.is-active {
  background: #fff;
  color: #0f172a;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.08);
}

.hydra-touch-pane {
  display: flex;
  flex-direction: column;
  min-height: 0;
  overflow: hidden;
}

.hydra-touch-pane[hidden] {
  display: none !important;
}

.hydra-touch-cursor-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
  gap: 8px;
  margin-bottom: 8px;
}

.hydra-touch-cursor-head h3 {
  margin: 0;
  font-size: 15px;
  font-weight: 800;
}

.hydra-touch-status {
  min-height: 28px;
  padding: 4px 8px;
  border-radius: 999px;
  background: #f1f5f9;
  color: #334155;
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.hydra-touch-status.is-online {
  background: #dcfce7;
  color: #166534;
}

.hydra-touch-status.is-running {
  background: #ffedd5;
  color: #9a3412;
}

.hydra-touch-status.is-waiting {
  background: #fef3c7;
  color: #92400e;
}

.hydra-touch-note,
.hydra-touch-recent-label {
  margin: 0 0 8px;
  color: #64748b;
  font-size: 13px;
  font-weight: 700;
}

.hydra-touch-worker {
  margin: 0 0 8px;
  padding: 8px 10px;
  border-radius: 12px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
}

.hydra-touch-worker.is-stale {
  background: #fff7ed;
  border-color: #fdba74;
}

.hydra-touch-worker.is-unknown {
  background: #f8fafc;
  border-color: #cbd5e1;
}

.hydra-touch-worker__warn {
  margin: 0 0 4px;
  color: #9a3412;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.35;
}

.hydra-touch-worker__line {
  margin: 0;
  color: #334155;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.45;
  overflow-wrap: anywhere;
}

.hydra-touch-worker__quiet {
  color: #64748b;
  font-weight: 600;
}

.hydra-touch-worker__oneline {
  margin: 0 0 8px;
  color: #64748b;
  font-size: 11px;
  font-weight: 650;
  line-height: 1.4;
  overflow-wrap: anywhere;
}

.hydra-touch-run {
  margin: 0 0 9px;
  padding: 13px 12px 12px;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: #fff;
}

.hydra-touch-run.is-active {
  border-color: #fdba74;
  background: #fff7ed;
}

.hydra-touch-run__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin: 0 0 5px;
  min-width: 0;
}

.hydra-touch-run__code {
  margin: 0;
  flex: 1 1 auto;
  min-width: 0;
  font-size: 13px;
  font-weight: 800;
  color: #0f172a;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hydra-touch-run__status {
  flex: 0 0 auto;
  font-size: 11px;
  font-weight: 750;
  color: #64748b;
  white-space: nowrap;
}

.hydra-touch-run__status.is-done {
  color: #15803d;
}

.hydra-touch-run__status.is-failed {
  color: #b91c1c;
}

.hydra-touch-run__status.is-cancelled {
  color: #64748b;
}

.hydra-touch-run__status.is-running,
.hydra-touch-run__status.is-received,
.hydra-touch-run__status.is-waiting,
.hydra-touch-run__status.is-queued {
  color: #c2410c;
}

.hydra-touch-run__sub {
  margin: 0;
  font-size: 0.8125rem;
  line-height: 1.35;
  color: var(--hydra-muted, #8a8f98);
  overflow-wrap: anywhere;
}

.hydra-touch-run__title {
  margin: 0 0 5px;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.35;
  color: #1e293b;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hydra-touch-run__usage {
  margin: 0 0 10px;
  font-size: 11px;
  font-weight: 650;
  color: #94a3b8;
  line-height: 1.35;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hydra-touch-run__recovery-hint {
  margin: -4px 0 8px;
  font-size: 11px;
  font-weight: 700;
  color: #0f766e;
  line-height: 1.35;
}

.hydra-touch-run__artifact-strip {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 0 0 8px;
  min-width: 0;
}

.hydra-touch-run__artifact-strip .hydra-touch-artifacts {
  flex: 1 1 auto;
  min-width: 0;
  margin: 0;
  gap: 5px;
  flex-wrap: nowrap;
}

.hydra-touch-run__artifact-strip .hydra-touch-artifacts__cell,
.hydra-touch-run__artifact-strip .hydra-touch-artifacts__item {
  width: 44px;
  flex-shrink: 0;
}

.hydra-touch-run__artifact-strip .hydra-touch-artifacts__img {
  width: 44px;
  height: 44px;
  border-radius: 8px;
  object-fit: cover;
}

.hydra-touch-run__artifact-strip .hydra-touch-artifacts__label {
  display: none;
}

.hydra-touch-usage-totals {
  margin: 0.25rem 0 0.45rem;
  padding: 0.35rem 0.5rem;
  border-radius: 8px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  font-size: 0.72rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px 10px;
}

.hydra-touch-usage-totals__row {
  margin: 0;
  display: flex;
  gap: 0.35rem;
  justify-content: space-between;
  min-width: 0;
}

.hydra-touch-usage-totals__row span {
  color: var(--hydra-muted, #8a8a8a);
}

.hydra-touch-usage__note {
  margin: 0.35rem 0 0;
  font-size: 0.72rem;
  color: var(--hydra-muted, #8a8a8a);
  line-height: 1.35;
}

.hydra-touch-usage__row--primary {
  font-weight: 700;
}

.hydra-touch-usage__row--primary span:first-child {
  color: #334155;
}

.hydra-touch-usage__dash {
  color: var(--hydra-muted, #8a8a8a);
}

.hydra-touch-run__meta {
  margin: 2px 0 6px;
  color: #64748b;
  font-size: 11px;
  font-weight: 700;
}

.hydra-touch-run__sum,
.hydra-touch-milestone {
  margin: 0 0 8px;
  min-width: 0;
  overflow: hidden;
  font-size: 12px;
  font-weight: 650;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.hydra-touch-run__sum {
  color: #0f172a;
}

.hydra-touch-milestone {
  color: #9a3412;
  font-weight: 750;
}

.hydra-touch-wait {
  margin: 0 0 6px;
  font-size: 14px;
  font-weight: 800;
  color: #92400e;
}

.hydra-touch-timeline {
  margin: 0 0 8px;
  padding: 0;
  list-style: none;
}

.hydra-touch-timeline li {
  margin: 0 0 2px;
  color: #334155;
  font-size: 13px;
  font-weight: 650;
}

.hydra-touch-timeline span {
  display: inline-block;
  min-width: 42px;
  font-variant-numeric: tabular-nums;
  color: #64748b;
}

.hydra-touch-run__actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.hydra-touch-run__actions-row {
  display: flex;
  gap: 7px;
  width: 100%;
  min-width: 0;
}

.hydra-touch-run__actions--row3 {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr) minmax(0, 1fr);
  gap: 7px;
}

.hydra-touch-run__actions--row2 {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr);
  gap: 7px;
}

.hydra-touch-run__actions--active {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 7px;
  align-items: stretch;
}

.hydra-touch-run__actions-row button,
.hydra-touch-run__actions > button {
  width: auto;
  min-width: 0;
  min-height: 44px;
  padding: 0 6px;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  background: #fff;
  color: #475569;
  font-size: 11px;
  font-weight: 750;
  cursor: pointer;
  box-sizing: border-box;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hydra-touch-run__actions button.is-primary {
  margin-top: 0;
  border: 0;
  background: #ea580c;
  color: #fff;
  font-size: 11px;
  font-weight: 800;
}

.hydra-touch-run__actions button.is-tertiary {
  min-height: 44px;
  padding: 0 10px;
  border: 1px solid #e2e8f0;
  background: #f8fafc;
  color: #64748b;
  font-size: 12px;
  font-weight: 700;
  align-self: stretch;
}

.hydra-touch-new {
  flex-shrink: 0;
  width: 100%;
  min-height: 50px;
  margin: 0 0 9px;
  border-radius: 12px;
  font-size: 15px;
  font-weight: 800;
  cursor: pointer;
}

.hydra-touch-runs {
  flex: 1 1 auto;
  min-height: 0;
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  touch-action: pan-y;
}

.hydra-touch-pane[data-touch-pane="cursor"] {
  flex: 1 1 auto;
  min-height: 0;
}

.hydra-touch-pane[data-touch-pane="images"] {
  flex: 1 1 auto;
  min-height: 0;
}

.hydra-touch-pane[data-touch-pane="images"] .hydra-touch-list {
  flex: 1 1 auto;
  min-height: 0;
}

.hydra-touch-report {
  max-height: 140px;
  margin: 0 0 8px;
  padding: 8px;
  overflow: auto;
  border-radius: 10px;
  background: #f8fafc;
  color: #0f172a;
  font: 13px/1.4 system-ui, sans-serif;
  white-space: pre-wrap;
  word-break: break-word;
}

.hydra-touch-composer {
  position: fixed;
  z-index: calc(var(--z-mobile-sheet, 6200) - 10);
  inset: 0;
  display: flex;
  align-items: flex-end;
  background: rgba(15, 23, 42, 0.28);
  padding: 12px;
  padding-bottom: calc(12px + env(safe-area-inset-bottom, 0px));
}

.hydra-touch-composer[hidden] {
  display: none;
}

.hydra-touch-composer__card {
  width: min(100%, 420px);
  margin: 0 auto;
  padding: 12px;
  border-radius: 18px 18px 14px 14px;
  background: #fff;
}

.hydra-touch-title,
.hydra-touch-prompt {
  width: 100%;
  box-sizing: border-box;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  color: #0f172a;
  font: 16px/1.4 system-ui, sans-serif;
}

.hydra-touch-title {
  min-height: 44px;
  margin-bottom: 8px;
  padding: 0 12px;
}

.hydra-touch-prompt {
  min-height: 160px;
  margin-bottom: 8px;
  padding: 12px;
  resize: vertical;
}

.hydra-touch-result {
  position: fixed;
  z-index: calc(var(--z-mobile-sheet, 6200) - 4);
  inset: 0;
  display: flex;
  align-items: flex-end;
  background: rgba(15, 23, 42, 0.28);
}

.hydra-touch-result[hidden] {
  display: none !important;
}

.hydra-touch-result__card {
  display: flex;
  flex-direction: column;
  width: 100%;
  height: auto;
  max-height: min(82dvh, 720px);
  box-sizing: border-box;
  padding: 14px 14px calc(12px + env(safe-area-inset-bottom, 0px));
  border-radius: 22px 22px 0 0;
  background: #fff;
}

.hydra-touch-recovery-banner {
  margin: 0 0 6px;
  color: #0f766e;
  font-size: 14px;
  font-weight: 800;
}

.hydra-touch-recovery-lines {
  margin: 0 0 8px;
  color: #334155;
  font-size: 13px;
  font-weight: 650;
  line-height: 1.4;
}

.hydra-touch-recovery-lines p {
  margin: 0 0 2px;
}

.hydra-touch-run__actions button.is-recover {
  flex: 1 0 auto;
}

.hydra-touch-result__body {
  min-height: 0;
  overflow: auto;
  -webkit-overflow-scrolling: touch;
}

.hydra-touch-result__sec {
  margin: 0 0 12px;
}

.hydra-touch-exec__row {
  margin: 0 0 4px;
  color: #334155;
  font-size: 13px;
  font-weight: 650;
  overflow-wrap: anywhere;
}

.hydra-touch-exec__row span {
  display: inline-block;
  min-width: 92px;
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
}

.hydra-touch-result__sec h3 {
  margin: 0 0 4px;
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.hydra-touch-result__sec p,
.hydra-touch-md p,
.hydra-touch-md li {
  margin: 0 0 6px;
  color: #0f172a;
  font-size: 15px;
  line-height: 1.45;
  overflow-wrap: anywhere;
}

.hydra-touch-md h4 {
  margin: 8px 0 4px;
  font-size: 15px;
  font-weight: 800;
}

.hydra-touch-md-list {
  margin: 0 0 6px;
  padding-left: 18px;
}

.hydra-touch-md-inline,
.hydra-touch-md-code,
.hydra-touch-raw {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.hydra-touch-md-inline {
  padding: 0 4px;
  border-radius: 6px;
  background: #f1f5f9;
  font-size: 13px;
}

.hydra-touch-md-code,
.hydra-touch-raw {
  margin: 0 0 8px;
  padding: 8px;
  overflow: auto;
  white-space: pre-wrap;
  border-radius: 10px;
  background: #f8fafc;
  color: #0f172a;
  font-size: 13px;
  line-height: 1.4;
}

.hydra-touch-raw-toggle {
  min-height: 44px;
  margin: 4px 0 8px;
  padding: 0;
  border: 0;
  background: transparent;
  color: #64748b;
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
}

.hydra-touch-result__actions {
  display: flex;
  flex-wrap: nowrap;
  gap: 8px;
  overflow-x: auto;
  padding-top: 8px;
}

.hydra-touch-result__actions button {
  flex: 1 0 132px;
  min-height: 44px;
  border-radius: 12px;
  font-size: 15px;
  font-weight: 800;
  cursor: pointer;
}

@media (min-width: 901px) {
  .hydra-touch-btn {
    left: 24px;
    bottom: 24px;
  }

  .hydra-touch-sheet {
    left: 24px;
    right: auto;
    bottom: 84px;
    width: 400px;
    max-height: min(70vh, 640px);
    max-height: min(70dvh, 640px);
    border-radius: 20px;
    padding-bottom: 14px;
  }

  .hydra-touch-composer,
  .hydra-touch-result {
    align-items: center;
    padding: 16px;
  }

  .hydra-touch-result__card {
    width: min(100%, 600px);
    border-radius: 18px;
    max-height: min(80vh, 720px);
  }
}

.hydra-touch-server-card {
  flex-shrink: 0;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  padding: 10px 12px;
  margin-bottom: 10px;
  background: #f8fafc;
}

.hydra-touch-server-dl {
  margin: 8px 0 0;
  display: grid;
  gap: 6px;
}

.hydra-touch-server-dl div {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  font-size: 13px;
}

.hydra-touch-server-dl dt {
  margin: 0;
  color: #64748b;
  font-weight: 700;
}

.hydra-touch-server-dl dd {
  margin: 0;
  text-align: right;
  font-weight: 800;
  color: #0f172a;
}

.hydra-touch-server-dl dd span {
  display: block;
  font-size: 11px;
  font-weight: 600;
  color: #64748b;
}

.hydra-touch-server-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 4px;
}

.hydra-touch-server-actions .hydra-touch-primary,
.hydra-touch-server-actions .hydra-touch-secondary {
  width: 100%;
  min-height: 44px;
}

.hydra-touch-danger-outline {
  border-color: #fecaca !important;
  color: #b91c1c !important;
  background: #fff !important;
}

.hydra-touch-server-card {
  background: #fff;
}

.hydra-touch-server-lines {
  margin: 0;
  padding-left: 18px;
  font-size: 14px;
  color: #334155;
}

.hydra-touch-server-lines li {
  margin: 4px 0;
}

.hydra-touch-pane[data-touch-pane="server"] {
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 4px;
}

.hydra-touch-artifacts {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: flex-start;
  margin: 6px 0 4px;
}

.hydra-touch-artifacts__cell {
  position: relative;
  width: 72px;
}

.hydra-touch-artifacts__item {
  border: none;
  padding: 0;
  margin: 0;
  background: transparent;
  width: 72px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  text-align: left;
}

.hydra-touch-artifacts__del {
  position: absolute;
  top: -4px;
  right: -4px;
  width: 22px;
  height: 22px;
  border: none;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.72);
  color: #fff;
  font-size: 14px;
  line-height: 1;
  cursor: pointer;
}

.hydra-touch-artifacts__img {
  display: block;
  width: 72px;
  height: 72px;
  object-fit: cover;
  border-radius: 10px;
  border: 1px solid rgba(15, 23, 42, 0.1);
  background: #f1f5f9;
}

.hydra-touch-artifacts__label {
  display: block;
  margin-top: 4px;
  font-size: 10px;
  line-height: 1.25;
  color: #64748b;
  overflow-wrap: anywhere;
}

.hydra-touch-artifacts__more {
  align-self: center;
  font-size: 12px;
  font-weight: 700;
  color: #64748b;
  padding: 4px 6px;
}

.hydra-touch-md-img {
  display: inline-block;
  border: none;
  padding: 0;
  margin: 6px 0;
  background: transparent;
  cursor: pointer;
  vertical-align: top;
  max-width: 100%;
}

.hydra-touch-md-img img {
  display: block;
  max-width: min(100%, 280px);
  width: auto;
  height: auto;
  max-height: 200px;
  object-fit: contain;
  border-radius: 10px;
  border: 1px solid rgba(15, 23, 42, 0.12);
  background: #f1f5f9;
}

.hydra-touch-md-img-denied {
  display: inline-block;
  font-size: 12px;
  color: #64748b;
  font-style: italic;
}

.hydra-touch-run__artifacts {
  margin: 4px 0 0;
  font-size: 12px;
  font-weight: 700;
  color: #ea580c;
}

.hydra-touch-run-artifacts {
  margin-bottom: 12px;
}

.hydra-touch-run-artifacts__head {
  margin: 0 0 2px;
  font-size: 13px;
  font-weight: 800;
  color: #0f172a;
}

.hydra-touch-run-artifacts__meta {
  margin: 0 0 6px;
  font-size: 12px;
  color: #64748b;
}

.hydra-touch-viewer__nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 4;
  border: none;
  width: 44px;
  height: 44px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.45);
  color: #fff;
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
}

.hydra-touch-viewer__nav--prev {
  left: max(8px, env(safe-area-inset-left, 0px));
}

.hydra-touch-viewer__nav--next {
  right: max(8px, env(safe-area-inset-right, 0px));
}

.hydra-touch-pane[data-touch-pane="gpt"] {
  display: flex;
  flex-direction: column;
  min-height: 0;
  flex: 1 1 auto;
  overflow: hidden;
}

.hydra-touch-gpt {
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: 0;
  flex: 1 1 auto;
  height: 100%;
  gap: 4px;
}

.hydra-touch-gpt-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  flex-shrink: 0;
}

.hydra-touch-gpt-head__main {
  min-width: 0;
  flex: 1 1 auto;
}

.hydra-touch-gpt-head__row {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.hydra-touch-gpt-head h3 {
  margin: 0;
  font-size: 16px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #0f172a;
  flex-shrink: 0;
}

.hydra-touch-gpt-status-pill {
  min-width: 0;
  flex: 1 1 auto;
  font-size: 11px;
  font-weight: 700;
  color: #64748b;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.hydra-touch-gpt-status-pill.is-ok {
  color: #64748b;
}

.hydra-touch-gpt-status-pill.is-busy,
.hydra-touch-gpt-status-pill.is-warn {
  color: #b45309;
}

.hydra-touch-gpt-status-pill.is-offline {
  color: #b91c1c;
}

.hydra-touch-gpt-meta {
  margin: 0 0 4px;
  font-size: 11px;
  font-weight: 600;
  color: #64748b;
}

.hydra-touch-gpt-totals {
  margin: 0;
  font-size: 11px;
  color: #475569;
  line-height: 1.35;
}

.hydra-touch-gpt-totals span {
  font-weight: 800;
  color: #334155;
}

.hydra-touch-gpt-usage-btn,
.hydra-touch-gpt-new {
  flex-shrink: 0;
  min-height: 44px;
  min-width: 44px;
  padding: 0 10px;
  border: 1px solid #e2e8f0;
  border-radius: 999px;
  background: #f8fafc;
  color: #334155;
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.hydra-touch-gpt-usage-sheet {
  flex-shrink: 0;
  padding: 8px 10px;
  border-radius: 12px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
}

.hydra-touch-gpt-usage-sheet__body {
  margin-bottom: 6px;
}

.hydra-touch-gpt-usage-close {
  width: 100%;
  min-height: 44px;
}

.hydra-touch-gpt-status-note {
  margin: 0;
  flex-shrink: 0;
  font-size: 12px;
}

.hydra-touch-gpt-thread {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 2px 0 4px;
}

.hydra-touch-gpt-empty {
  margin: 8px 0;
  font-size: 13px;
  color: #64748b;
}

.hydra-touch-gpt-msg {
  font-size: 14px;
  line-height: 1.45;
  color: #0f172a;
}

.hydra-touch-gpt-msg p {
  margin: 0;
  white-space: pre-wrap;
  word-break: break-word;
}

.hydra-touch-gpt-md {
  font-size: 14px;
  line-height: 1.45;
  color: #0f172a;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.hydra-touch-gpt-md p {
  margin: 0 0 8px;
  white-space: normal;
}

.hydra-touch-gpt-md p:last-child {
  margin-bottom: 0;
}

.hydra-touch-gpt-md h1,
.hydra-touch-gpt-md h2,
.hydra-touch-gpt-md h3 {
  margin: 0 0 6px;
  font-size: 15px;
  font-weight: 800;
  line-height: 1.3;
}

.hydra-touch-gpt-md ul,
.hydra-touch-gpt-md ol {
  margin: 0 0 8px;
  padding-left: 1.25rem;
}

.hydra-touch-gpt-md li {
  margin: 0 0 4px;
}

.hydra-touch-gpt-code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.92em;
  padding: 1px 4px;
  border-radius: 4px;
  background: #f1f5f9;
}

.hydra-touch-gpt-pre {
  margin: 0 0 8px;
  padding: 8px 10px;
  border-radius: 10px;
  background: #0f172a;
  color: #e2e8f0;
  overflow-x: auto;
  max-width: 100%;
  -webkit-overflow-scrolling: touch;
}

.hydra-touch-gpt-pre code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 12px;
  line-height: 1.4;
  white-space: pre;
  word-break: normal;
}

.hydra-touch-gpt-msg.is-user {
  padding: 8px 10px;
  border-radius: 10px;
  background: #fff7ed;
  border: 1px solid rgba(249, 115, 22, 0.18);
}

.hydra-touch-gpt-msg.is-assistant {
  padding: 2px 2px 2px 0;
}

.hydra-touch-gpt-msg.is-pending {
  color: #64748b;
  font-size: 13px;
}

.hydra-touch-gpt-msg.is-error {
  color: #b91c1c;
  font-size: 13px;
}

.hydra-touch-gpt-usage-line {
  margin-top: 4px;
  padding: 0;
  border: 0;
  background: none;
  font-size: 11px;
  font-weight: 700;
  color: #64748b;
  cursor: pointer;
  text-align: left;
}

.hydra-touch-gpt-usage {
  margin: 6px 0 0;
  font-size: 11px;
  color: #475569;
}

.hydra-touch-gpt-usage dt {
  font-weight: 800;
  margin-top: 4px;
}

.hydra-touch-gpt-usage dd {
  margin: 0;
}

.hydra-touch-gpt-history {
  flex-shrink: 0;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin: 0 -2px;
  padding: 0 2px 2px;
}

.hydra-touch-gpt-history ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: row;
  gap: 6px;
  min-width: min-content;
}

.hydra-touch-gpt-history-item {
  flex-shrink: 0;
  max-width: 140px;
  min-height: 44px;
  text-align: left;
  border: 1px solid #e2e8f0;
  background: #f8fafc;
  border-radius: 999px;
  padding: 6px 10px;
  font-size: 11px;
  font-weight: 700;
  color: #334155;
  cursor: pointer;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  -webkit-tap-highlight-color: transparent;
}

.hydra-touch-gpt-history-item.is-active {
  border-color: rgba(249, 115, 22, 0.35);
  background: #fff7ed;
  color: #9a3412;
}

.hydra-touch-gpt-history-li {
  flex-shrink: 0;
}

.hydra-touch-gpt-history-chip {
  display: inline-flex;
  align-items: stretch;
  max-width: 160px;
  border-radius: 999px;
  overflow: hidden;
  border: 1px solid #e2e8f0;
  background: #f8fafc;
}

.hydra-touch-gpt-history-chip .hydra-touch-gpt-history-item {
  border: 0;
  border-radius: 0;
  max-width: 120px;
  min-height: 40px;
}

.hydra-touch-gpt-history-chip .hydra-touch-gpt-history-item.is-active {
  background: #fff7ed;
}

.hydra-touch-gpt-history-more,
.hydra-touch-gpt-msg-more,
.hydra-touch-gpt-panel__more {
  border: 0;
  background: transparent;
  color: #64748b;
  font-size: 14px;
  line-height: 1;
  padding: 0 8px;
  min-width: 32px;
  min-height: 32px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.hydra-touch-gpt-history-more {
  border-left: 1px solid #e2e8f0;
  background: #f1f5f9;
  font-weight: 700;
}

.hydra-touch-gpt-history-list {
  flex-shrink: 0;
  min-height: 40px;
  border: 1px dashed #cbd5e1;
  background: #fff;
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 11px;
  font-weight: 700;
  color: #475569;
  cursor: pointer;
}

.hydra-touch-gpt-msg__bar {
  display: flex;
  justify-content: flex-end;
  margin: -2px 0 2px;
}

.hydra-touch-gpt-msg-more {
  opacity: 0.55;
  padding: 2px 4px;
  min-height: 28px;
  min-width: 28px;
}

.hydra-touch-gpt-msg:hover .hydra-touch-gpt-msg-more,
.hydra-touch-gpt-msg:focus-within .hydra-touch-gpt-msg-more {
  opacity: 1;
}

.hydra-touch-gpt-overlay-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.35);
  z-index: 12;
}

.hydra-touch-gpt-overlays {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 13;
}

.hydra-touch-gpt-overlays > * {
  pointer-events: auto;
}

.hydra-touch-gpt-overlays > [hidden] {
  display: none !important;
  pointer-events: none !important;
}

.hydra-touch-gpt-menu,
.hydra-touch-gpt-rename,
.hydra-touch-gpt-delete,
.hydra-touch-gpt-panel {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  width: min(340px, calc(100% - 16px));
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  box-shadow: 0 12px 40px rgba(15, 23, 42, 0.18);
  padding: 10px;
  box-sizing: border-box;
}

.hydra-touch-gpt-menu {
  bottom: 72px;
}

.hydra-touch-gpt-menu__title {
  margin: 0 0 8px;
  font-size: 12px;
  font-weight: 700;
  color: #334155;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.hydra-touch-gpt-menu button {
  display: block;
  width: 100%;
  text-align: left;
  border: 0;
  background: #f8fafc;
  border-radius: 10px;
  padding: 10px 12px;
  margin: 0 0 6px;
  font-size: 14px;
  font-weight: 600;
  color: #0f172a;
  cursor: pointer;
}

.hydra-touch-gpt-menu button.is-danger {
  color: #b91c1c;
  background: #fef2f2;
}

.hydra-touch-gpt-menu__cancel {
  background: transparent !important;
  color: #64748b !important;
  text-align: center !important;
}

.hydra-touch-gpt-rename,
.hydra-touch-gpt-delete {
  top: 18%;
}

.hydra-touch-gpt-rename__label {
  display: block;
  font-size: 12px;
  font-weight: 700;
  color: #475569;
  margin-bottom: 6px;
}

.hydra-touch-gpt-rename__input {
  width: 100%;
  box-sizing: border-box;
  border: 1px solid #cbd5e1;
  border-radius: 10px;
  padding: 10px 12px;
  font-size: 15px;
  margin-bottom: 10px;
}

.hydra-touch-gpt-rename__actions,
.hydra-touch-gpt-delete__actions {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
}

.hydra-touch-gpt-panel {
  bottom: 0;
  top: auto;
  left: 0;
  right: 0;
  transform: none;
  width: auto;
  max-height: min(70vh, 520px);
  border-radius: 16px 16px 0 0;
  display: flex;
  flex-direction: column;
  padding: 0;
}

.hydra-touch-gpt-panel__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  border-bottom: 1px solid #e2e8f0;
}

.hydra-touch-gpt-panel__head h4 {
  margin: 0;
  font-size: 14px;
}

.hydra-touch-gpt-panel__close {
  border: 0;
  background: transparent;
  font-size: 22px;
  line-height: 1;
  padding: 4px 8px;
  cursor: pointer;
}

.hydra-touch-gpt-panel__list {
  list-style: none;
  margin: 0;
  padding: 6px 0;
  overflow-y: auto;
}

.hydra-touch-gpt-panel__list li {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 0 6px;
}

.hydra-touch-gpt-panel__row {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  border: 0;
  background: transparent;
  text-align: left;
  padding: 10px 8px;
  border-radius: 10px;
  cursor: pointer;
}

.hydra-touch-gpt-panel__row.is-active {
  background: #fff7ed;
}

.hydra-touch-gpt-panel__title {
  font-size: 13px;
  font-weight: 700;
  color: #0f172a;
}

.hydra-touch-gpt-panel__meta {
  font-size: 11px;
  color: #64748b;
}

.hydra-touch-gpt-toast {
  position: absolute;
  left: 50%;
  bottom: 88px;
  transform: translateX(-50%);
  z-index: 14;
  margin: 0;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.88);
  color: #fff;
  font-size: 12px;
  font-weight: 600;
  pointer-events: none;
}

.hydra-touch-gpt {
  position: relative;
}

@media (min-width: 901px) {
  .hydra-touch-gpt-panel {
    bottom: auto;
    top: 96px;
    left: auto;
    right: 8px;
    width: min(320px, calc(100% - 16px));
    max-height: min(420px, 60vh);
    border-radius: 14px;
  }

  .hydra-touch-gpt-menu {
    bottom: auto;
    top: 96px;
    right: 8px;
    left: auto;
    transform: none;
  }
}

.hydra-touch-gpt-composer {
  flex-shrink: 0;
  margin-top: auto;
  padding-top: 2px;
  padding-bottom: max(0px, env(safe-area-inset-bottom, 0px));
  position: sticky;
  bottom: 0;
  z-index: 2;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0) 0%, #fff 28%);
}

.hydra-touch-gpt-composer__box {
  display: flex;
  align-items: flex-end;
  gap: 4px;
  min-height: 48px;
  padding: 4px 4px 4px 10px;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  background: #f8fafc;
  box-sizing: border-box;
}

#hydraTouchRoot .hydra-touch-gpt-composer__box .hydra-touch-gpt-input,
#hydraToolsShell #hydraTouchRoot .hydra-touch-gpt-composer__box .hydra-touch-gpt-input {
  flex: 1 1 auto;
  align-self: center;
  min-width: 0;
  height: 36px !important;
  min-height: 36px !important;
  max-height: 96px !important;
  resize: none;
  overflow-y: hidden;
  overflow-x: hidden;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent;
  padding: 8px 0;
  font-size: 15px !important;
  line-height: 1.35;
  font-family: inherit;
  box-sizing: border-box;
}

#hydraTouchRoot .hydra-touch-gpt-composer__box .hydra-touch-gpt-input.is-multiline,
#hydraToolsShell #hydraTouchRoot .hydra-touch-gpt-composer__box .hydra-touch-gpt-input.is-multiline {
  height: auto !important;
  overflow-y: auto;
}

.hydra-touch-gpt-send {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  min-width: 44px;
  min-height: 44px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: #f97316;
  color: #fff;
  font-size: 20px;
  font-weight: 800;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  -webkit-tap-highlight-color: transparent;
}

.hydra-touch-gpt-send:disabled {
  opacity: 0.45;
  cursor: default;
}

.hydra-touch-gpt-clip {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  min-width: 44px;
  min-height: 44px;
  padding: 0;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: #475569;
  font-size: 18px;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.hydra-touch-gpt-clip:disabled {
  opacity: 0.35;
  cursor: default;
}

.hydra-touch-gpt-attach-strip {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding: 0 2px 8px;
  max-height: 80px;
  -webkit-overflow-scrolling: touch;
}

.hydra-touch-gpt-attach-slot {
  position: relative;
  flex: 0 0 72px;
  width: 72px;
  height: 72px;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid #e2e8f0;
  background: #f1f5f9;
}

.hydra-touch-gpt-attach-slot img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.hydra-touch-gpt-attach-slot.is-error {
  border-color: #fca5a5;
}

.hydra-touch-gpt-attach-slot.is-upload {
  opacity: 0.75;
}

.hydra-touch-gpt-attach-slot__remove {
  position: absolute;
  top: 2px;
  right: 2px;
  width: 28px;
  height: 28px;
  min-width: 28px;
  min-height: 28px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.65);
  color: #fff;
  font-size: 14px;
  line-height: 1;
  cursor: pointer;
}

.hydra-touch-gpt-attach-slot__retry {
  position: absolute;
  bottom: 4px;
  left: 4px;
  right: 4px;
  height: 22px;
  padding: 0 4px;
  border: 0;
  border-radius: 6px;
  background: #fef2f2;
  color: #b91c1c;
  font-size: 9px;
  font-weight: 800;
  cursor: pointer;
}

.hydra-touch-gpt-attach-slot__spin {
  position: absolute;
  inset: 0;
  margin: auto;
  width: 22px;
  height: 22px;
  border: 2px solid rgba(15, 23, 42, 0.12);
  border-top-color: #f97316;
  border-radius: 999px;
  animation: hydra-touch-gpt-spin 0.8s linear infinite;
}

.hydra-touch-gpt-attach-slot__state {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 26px;
  padding: 2px 3px;
  background: rgba(15, 23, 42, 0.72);
  color: #f8fafc;
  font-size: 8px;
  font-weight: 700;
  line-height: 1.15;
  text-align: center;
  overflow: hidden;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  pointer-events: none;
}

.hydra-touch-gpt-attach-slot__state.is-error {
  bottom: 28px;
  background: rgba(127, 29, 29, 0.88);
  color: #fef2f2;
}

.hydra-touch-gpt-attach-slot__size {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 2px;
  padding: 1px 2px;
  background: rgba(15, 23, 42, 0.62);
  color: #e2e8f0;
  font-size: 7px;
  font-weight: 700;
  line-height: 1.1;
  text-align: center;
  pointer-events: none;
}

@keyframes hydra-touch-gpt-spin {
  to {
    transform: rotate(360deg);
  }
}

.hydra-touch-gpt-composer__box.is-drop-hint {
  outline: 2px dashed #f97316;
  outline-offset: -4px;
  background: #fff7ed;
}

.hydra-touch-gpt-msg-imgs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  margin-top: 8px;
  max-width: 260px;
}

.hydra-touch-gpt-msg-img {
  display: block;
  padding: 0;
  border: 0;
  border-radius: 10px;
  overflow: hidden;
  cursor: pointer;
  background: #e2e8f0;
  min-height: 0;
}

.hydra-touch-gpt-msg-img img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  display: block;
}

.hydra-touch-gpt-img-view {
  position: fixed;
  inset: 0;
  z-index: 120;
  background: rgba(15, 23, 42, 0.92);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px 12px 24px;
  box-sizing: border-box;
}

.hydra-touch-gpt-img-view[hidden] {
  display: none !important;
}

.hydra-touch-gpt-img-view img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  border-radius: 8px;
}

.hydra-touch-gpt-img-view__close {
  position: absolute;
  top: max(12px, env(safe-area-inset-top, 12px));
  right: 12px;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
  font-size: 22px;
  cursor: pointer;
}

/* TASK-1301 GPT workspace */
.hydra-touch-gpt-home,
.hydra-touch-gpt-chat {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  min-height: 0;
  gap: 4px;
}

.hydra-touch-gpt-home-head,
.hydra-touch-gpt-chat-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-shrink: 0;
  min-height: 44px;
}

.hydra-touch-gpt-home-head h2,
.hydra-touch-gpt-chat-head__title {
  margin: 0;
  font-size: 16px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #0f172a;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.hydra-touch-gpt-home-head__actions,
.hydra-touch-gpt-chat-head__actions {
  display: flex;
  gap: 4px;
  align-items: center;
  flex-shrink: 0;
}

.hydra-touch-gpt-icon-btn {
  min-width: 44px;
  min-height: 44px;
  border: 0;
  background: transparent;
  font-size: 18px;
  color: #475569;
  border-radius: 10px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.hydra-touch-gpt-pill-btn {
  min-height: 36px;
  padding: 0 12px;
  border: 1px solid #e2e8f0;
  border-radius: 999px;
  background: #f8fafc;
  color: #334155;
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.hydra-touch-gpt-pill-btn--accent {
  background: #fff7ed;
  border-color: #fed7aa;
  color: #c2410c;
}

.hydra-touch-gpt-search {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  margin-bottom: 4px;
  border-radius: 11px;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
}

.hydra-touch-gpt-search__input {
  flex: 1;
  border: 0;
  background: transparent;
  font-size: 14px;
  font-weight: 600;
  outline: none;
  min-width: 0;
}

.hydra-touch-gpt-search__close {
  border: 0;
  background: transparent;
  min-width: 44px;
  min-height: 44px;
  font-size: 18px;
  color: #64748b;
  cursor: pointer;
}

.hydra-touch-gpt-home-list {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 8px;
}

.hydra-touch-gpt-sec {
  margin: 0 0 6px;
  font-size: 11px;
  font-weight: 800;
  color: #64748b;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.hydra-touch-gpt-conv-row {
  display: flex;
  align-items: center;
  gap: 6px;
  width: 100%;
  min-height: 48px;
  padding: 8px 10px;
  margin-bottom: 6px;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: #fff;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.hydra-touch-gpt-conv-row.is-pinned {
  border-color: #fed7aa;
  background: #fffbf7;
}

.hydra-touch-gpt-conv-row.is-skeleton {
  opacity: 0.45;
}

.hydra-touch-gpt-conv-row__pin {
  font-size: 12px;
  color: #ea580c;
  flex-shrink: 0;
}

.hydra-touch-gpt-conv-row__main {
  flex: 1;
  min-width: 0;
  border: 0;
  background: transparent;
  padding: 0;
  text-align: left;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.hydra-touch-gpt-conv-row__title {
  display: block;
  font-size: 14px;
  font-weight: 800;
  color: #0f172a;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.hydra-touch-gpt-conv-row__meta {
  display: block;
  margin-top: 2px;
  font-size: 11px;
  font-weight: 700;
  color: #94a3b8;
}

.hydra-touch-gpt-conv-row__more {
  width: 44px;
  height: 44px;
  flex-shrink: 0;
  border: 0;
  background: transparent;
  font-size: 18px;
  color: #94a3b8;
  cursor: pointer;
}

.hydra-touch-gpt-home-empty {
  margin: 16px 0;
  font-size: 13px;
  color: #64748b;
  text-align: center;
}

.hydra-touch-gpt-home-new {
  display: block;
  width: 100%;
  margin-top: 8px;
}

.hydra-touch-gpt-back {
  width: 44px;
  height: 44px;
  flex-shrink: 0;
  border: 0;
  background: transparent;
  font-size: 26px;
  font-weight: 300;
  color: #475569;
  line-height: 1;
  cursor: pointer;
}

.hydra-touch-gpt-chat-head__title {
  flex: 1 1 auto;
  font-size: 15px;
}

.hydra-touch-gpt-ghost-chip {
  min-height: 32px;
  padding: 0 10px;
  border: 0;
  background: transparent;
  font-size: 12px;
  font-weight: 800;
  color: #475569;
  cursor: pointer;
}

.hydra-touch-gpt-ghost-chip--pin {
  color: #c2410c;
}

.hydra-touch-gpt-chat-search {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 8px;
  margin-bottom: 4px;
  border-radius: 11px;
  background: #fff7ed;
  border: 1px solid #fed7aa;
}

.hydra-touch-gpt-chat-search__input {
  flex: 1;
  border: 0;
  background: transparent;
  font-size: 14px;
  font-weight: 600;
  outline: none;
  min-width: 0;
}

.hydra-touch-gpt-chat-search__count {
  font-size: 11px;
  font-weight: 800;
  color: #64748b;
  white-space: nowrap;
}

.hydra-touch-gpt-chat-search__nav button {
  width: 36px;
  height: 36px;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #fff;
  font-size: 14px;
  color: #475569;
  cursor: pointer;
}

.hydra-touch-gpt-thread-wrap {
  position: relative;
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
}

.hydra-touch-gpt-thread-wrap .hydra-touch-gpt-thread {
  flex: 1 1 auto;
}

.hydra-touch-gpt-msg-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 12px;
  margin-top: 8px;
  padding-top: 4px;
}

.hydra-touch-gpt-msg.is-user .hydra-touch-gpt-msg-actions {
  justify-content: flex-end;
}

.hydra-touch-gpt-msg-actions button {
  border: 0;
  background: transparent;
  padding: 6px 0;
  min-height: 36px;
  font-size: 12px;
  font-weight: 800;
  color: #64748b;
  cursor: pointer;
}

.hydra-touch-gpt-msg-actions button.is-on {
  color: #c2410c;
}

.hydra-touch-gpt-msg.is-highlight {
  outline: 2px solid #fed7aa;
  outline-offset: 2px;
  border-radius: 10px;
}

.hydra-touch-gpt-code-wrap {
  position: relative;
  margin: 8px 0;
  border-radius: 10px;
  background: #0f172a;
  overflow: hidden;
}

.hydra-touch-gpt-code-wrap .hydra-touch-gpt-pre {
  margin: 0;
  padding: 10px 12px 32px;
  border-radius: 0;
}

.hydra-touch-gpt-code-copy {
  position: absolute;
  right: 8px;
  bottom: 6px;
  border: 0;
  background: rgba(255, 255, 255, 0.12);
  color: #f8fafc;
  font-size: 11px;
  font-weight: 800;
  padding: 4px 8px;
  border-radius: 6px;
  cursor: pointer;
}

.hydra-touch-gpt-handoff-box {
  margin-top: 10px;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px dashed #fdba74;
  background: #fff7ed;
}

.hydra-touch-gpt-handoff-box p {
  margin: 0 0 8px;
  font-size: 12px;
  font-weight: 700;
  color: #9a3412;
}

.hydra-touch-gpt-handoff-box .hydra-touch-primary {
  width: 100%;
  min-height: 44px;
}

.hydra-touch-gpt-handoff-box__hint {
  margin: 8px 0 0 !important;
  font-size: 11px !important;
  font-weight: 600 !important;
  color: #94a3b8 !important;
  text-align: center;
}

.hydra-touch-gpt-cursor-result {
  margin: 8px 0;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid #bfdbfe;
  background: #eff6ff;
}

.hydra-touch-gpt-cursor-result.is-compact {
  margin: 0 0 6px;
  padding: 8px 10px;
  border-radius: 10px;
}

.hydra-touch-gpt-cursor-result__compact-title {
  margin: 0 0 2px;
  font-size: 12px;
  font-weight: 800;
  color: #1e3a8a;
  line-height: 1.25;
}

.hydra-touch-gpt-cursor-result__compact-meta {
  margin: 0 0 6px;
  font-size: 11px;
  font-weight: 700;
  color: #475569;
  line-height: 1.3;
}

.hydra-touch-gpt-cursor-result.is-compact .hydra-touch-gpt-cursor-result__actions {
  margin: 0;
}

.hydra-touch-gpt-cursor-result.is-compact .hydra-touch-gpt-cursor-result__actions button {
  min-height: 36px;
  padding: 0 10px;
  font-size: 11px;
}

.hydra-touch-gpt-lineage {
  margin: 0 0 8px;
}

.hydra-touch-gpt-lineage .hydra-touch-gpt-review {
  margin-top: 0;
}

.hydra-touch-gpt-lineage .hydra-touch-gpt-auto-fix-chip {
  margin: 4px 0 0;
}

.hydra-touch-gpt-cursor-result__head {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
  min-width: 0;
}

.hydra-touch-gpt-cursor-result__badge {
  font-size: 10px;
  font-weight: 800;
  padding: 2px 6px;
  border-radius: 6px;
  background: #1d4ed8;
  color: #fff;
  flex-shrink: 0;
}

.hydra-touch-gpt-cursor-result__title {
  font-size: 13px;
  font-weight: 800;
  color: #1e3a8a;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hydra-touch-gpt-cursor-result__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.hydra-touch-gpt-handoff-round {
  margin: 0 0 0.35rem;
  font-size: 0.8125rem;
  color: var(--hydra-touch-muted, #6b7280);
}

.hydra-touch-gpt-review {
  margin: 0.5rem 0 0.75rem;
  padding: 0.65rem 0.75rem;
  border-radius: 10px;
  border: 1px solid var(--hydra-touch-border, #e5e7eb);
  background: var(--hydra-touch-surface, #fff);
  font-size: 0.875rem;
}

.hydra-touch-gpt-review.is-pass {
  padding: 0.45rem 0.65rem;
  border-style: dashed;
}

.hydra-touch-gpt-review.is-fix {
  border-color: color-mix(in srgb, var(--hydra-orange, #e85d04) 35%, #e5e7eb);
}

.hydra-touch-gpt-review.is-check {
  border-color: #d1d5db;
}

.hydra-touch-gpt-review.is-pending {
  opacity: 0.92;
}

.hydra-touch-gpt-review.is-error {
  border-color: #fecaca;
}

.hydra-touch-gpt-review__head {
  margin: 0 0 0.25rem;
  font-size: 0.75rem;
  color: var(--hydra-touch-muted, #6b7280);
}

.hydra-touch-gpt-review__verdict {
  margin: 0;
  font-weight: 600;
}

.hydra-touch-gpt-review__bullets {
  margin: 0.35rem 0 0.5rem;
  padding-left: 1.1rem;
}

.hydra-touch-gpt-review__bullets li {
  margin: 0.15rem 0;
}

.hydra-touch-gpt-review__detail-toggle {
  display: block;
  margin: 0.25rem 0 0.5rem;
  padding: 0;
  border: 0;
  background: none;
  color: var(--hydra-orange, #e85d04);
  font-size: 0.8125rem;
  text-decoration: underline;
  cursor: pointer;
}

.hydra-touch-gpt-review__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 0.35rem;
}

.hydra-touch-gpt-review__actions .hydra-touch-primary,
.hydra-touch-gpt-review__actions .hydra-touch-secondary {
  flex: 1 1 auto;
  min-width: 0;
}

.hydra-touch-gpt-cursor-result__actions button {
  min-height: 40px;
  padding: 0 12px;
  border: 1px solid #93c5fd;
  border-radius: 10px;
  background: #fff;
  font-size: 12px;
  font-weight: 800;
  color: #1d4ed8;
  cursor: pointer;
}

.hydra-touch-gpt-new-chip {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  bottom: 8px;
  z-index: 5;
  min-height: 36px;
  padding: 0 14px;
  border-radius: 999px;
  border: 1px solid #e2e8f0;
  background: #fff;
  box-shadow: 0 4px 16px rgba(15, 23, 42, 0.12);
  font-size: 12px;
  font-weight: 800;
  color: #334155;
  cursor: pointer;
}

.hydra-touch-gpt-search-mark {
  background: #fed7aa;
  padding: 0 2px;
  border-radius: 2px;
}

.hydra-touch-gpt-search-mark.is-current {
  background: #fb923c;
}

.hydra-touch-gpt-sheet-scrim {
  position: absolute;
  inset: 0;
  z-index: 20;
  background: rgba(15, 23, 42, 0.28);
  display: flex;
  align-items: flex-end;
}

.hydra-touch-gpt-sheet {
  width: 100%;
  max-height: 72%;
  background: #fff;
  border-radius: 22px 22px 0 0;
  padding: 12px 14px max(16px, env(safe-area-inset-bottom, 16px));
  box-shadow: 0 -8px 32px rgba(15, 23, 42, 0.12);
  overflow-y: auto;
}

.hydra-touch-gpt-sheet__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}

.hydra-touch-gpt-sheet__head h3 {
  margin: 0;
  font-size: 16px;
  font-weight: 800;
}

.hydra-touch-gpt-sheet__close {
  width: 44px;
  height: 44px;
  border: 0;
  background: transparent;
  font-size: 22px;
  color: #64748b;
  cursor: pointer;
}

.hydra-touch-gpt-pin-item {
  display: block;
  width: 100%;
  text-align: left;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 10px 12px;
  margin-bottom: 8px;
  background: #fff;
  cursor: pointer;
}

.hydra-touch-gpt-pin-item__role {
  font-size: 10px;
  font-weight: 800;
  color: #94a3b8;
  text-transform: uppercase;
}

.hydra-touch-gpt-pin-item__preview {
  margin: 4px 0 0;
  font-size: 13px;
  font-weight: 600;
  color: #334155;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.hydra-touch-gpt-handoff-excerpt {
  white-space: pre-wrap;
  max-height: 8.5rem;
  overflow: auto;
  padding: 8px 10px;
  border-radius: 10px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  font-size: 12px;
  font-weight: 600;
  color: #334155;
  line-height: 1.4;
  margin: 0;
}

.hydra-touch-gpt-handoff-sheet {
  max-height: min(78dvh, 640px);
}

.hydra-touch-gpt-handoff-sheet__head {
  margin-bottom: 8px;
}

.hydra-touch-gpt-handoff-sheet__body {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.hydra-touch-gpt-handoff-sheet__meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.hydra-touch-gpt-handoff-sheet__dest {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #1d4ed8;
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  padding: 4px 8px;
  border-radius: 8px;
}

.hydra-touch-gpt-handoff-sheet__round {
  font-size: 11px;
  font-weight: 700;
  color: #64748b;
  padding: 4px 8px;
  border-radius: 8px;
  background: #f1f5f9;
}

.hydra-touch-gpt-handoff-sheet__lead {
  margin: 0;
  font-size: 12px;
  font-weight: 600;
  color: #64748b;
  line-height: 1.4;
}

.hydra-touch-gpt-handoff-sheet__excerpt-label {
  margin: 0 0 4px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #94a3b8;
}

.hydra-touch-gpt-handoff-sheet__opts {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.hydra-touch-gpt-handoff-opt {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid #e2e8f0;
  background: #fff;
  cursor: pointer;
  margin: 0;
}

.hydra-touch-gpt-handoff-opt:has(input:focus-visible) {
  outline: 2px solid #fdba74;
  outline-offset: 2px;
}

.hydra-touch-gpt-handoff-opt:has(input:checked) {
  border-color: #fdba74;
  background: #fff7ed;
  box-shadow: 0 0 0 1px rgba(234, 88, 12, 0.1);
}

.hydra-touch-gpt-handoff-opt input {
  flex-shrink: 0;
  width: 18px;
  height: 18px;
  margin: 1px 0 0;
  accent-color: #ea580c;
  cursor: pointer;
}

.hydra-touch-gpt-handoff-opt__text {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}

.hydra-touch-gpt-handoff-opt__title {
  font-size: 13px;
  font-weight: 800;
  color: #0f172a;
  line-height: 1.25;
}

.hydra-touch-gpt-handoff-opt__hint {
  font-size: 11px;
  font-weight: 500;
  color: #64748b;
  line-height: 1.35;
}

.hydra-touch-gpt-handoff-sheet__actions {
  display: flex;
  flex-direction: column-reverse;
  gap: 8px;
  margin-top: 2px;
  padding-top: 10px;
  border-top: 1px solid #f1f5f9;
}

.hydra-touch-gpt-handoff-sheet__actions .hydra-touch-primary,
.hydra-touch-gpt-handoff-sheet__actions .hydra-touch-secondary {
  width: 100%;
  min-height: 44px;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 800;
}

.hydra-touch-gpt-handoff-ok {
  margin: 0;
}

.hydra-touch-gpt-handoff-ok:disabled {
  cursor: not-allowed;
}

.hydra-touch-gpt-auto-fix-opt {
  display: flex;
  gap: 8px;
  align-items: flex-start;
  font-size: 13px;
  font-weight: 600;
  color: #334155;
  margin: 0 0 6px;
  cursor: pointer;
}

.hydra-touch-gpt-handoff-sheet .hydra-touch-gpt-auto-fix-opt {
  margin: 0;
}

.hydra-touch-gpt-auto-fix-opt input {
  margin-top: 2px;
  accent-color: #ea580c;
}

.hydra-touch-gpt-auto-fix-opt__hint {
  font-size: 11px;
  font-weight: 500;
  color: #64748b;
  line-height: 1.35;
  margin: 0 0 12px;
}

.hydra-touch-gpt-auto-fix-chip {
  font-size: 11px;
  font-weight: 700;
  color: #9a3412;
  margin: 6px 0 0;
  padding: 0;
}

.hydra-touch-gpt-production {
  margin: 8px 0 0;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid #e2e8f0;
  background: #f8fafc;
}

.hydra-touch-gpt-production__title {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #475569;
  margin: 0 0 8px;
}

.hydra-touch-gpt-production__steps {
  list-style: none;
  margin: 0;
  padding: 0;
}

.hydra-touch-gpt-production__steps li {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 12px;
  line-height: 1.35;
  color: #64748b;
  margin: 0 0 4px;
}

.hydra-touch-gpt-production__steps li.is-active {
  color: #0f172a;
  font-weight: 600;
}

.hydra-touch-gpt-production__steps li.is-done {
  color: #15803d;
}

.hydra-touch-gpt-production__steps li.is-fail {
  color: #b91c1c;
}

.hydra-touch-gpt-production__badge {
  flex: 0 0 auto;
  width: 14px;
  text-align: center;
  font-weight: 700;
}

.hydra-touch-gpt-production__verdict {
  font-size: 12px;
  font-weight: 700;
  margin: 8px 0 0;
}

.hydra-touch-gpt-production__verdict.is-pass {
  color: #15803d;
}

.hydra-touch-gpt-production__verdict.is-fail {
  color: #b91c1c;
}

.hydra-touch-gpt-auto-prod-opt {
  margin-top: 8px;
}

.hydra-touch-gpt-handoff-sheet .hydra-touch-gpt-auto-prod-opt {
  margin-top: 0;
}

.hydra-touch-gpt-status-pill--sheet {
  display: inline-block;
  margin-bottom: 6px;
}

.hydra-touch-gpt-msg.is-user {
  align-self: flex-end;
  max-width: 92%;
  padding: 10px 12px;
  border-radius: 14px 14px 4px 14px;
  background: #f1f5f9;
  border: 0;
}

.hydra-touch-gpt-msg.is-assistant {
  padding: 2px 0;
}

@media (max-width: 900px) {
  #hydraTouchRoot.is-open .hydra-touch-sheet {
    display: flex;
    flex-direction: column;
  }

  #hydraTouchRoot.is-open .hydra-touch-sheet > .hydra-touch-pane:not([hidden]) {
    flex: 1 1 auto;
    min-height: 0;
  }

  #hydraTouchRoot.is-open .hydra-touch-pane[data-touch-pane="gpt"]:not([hidden]) {
    flex: 1 1 auto;
    min-height: 0;
  }
}

.hydra-touch-gpt-flow {
  margin: 8px 0;
  padding: 8px 10px;
  border-radius: 12px;
  border: 1px solid #e2e8f0;
  background: #f8fafc;
}

.hydra-touch-gpt-flow.is-wait-cursor {
  border-style: dashed;
  opacity: 0.92;
}

.hydra-touch-gpt-flow.is-wait-cursor .hydra-touch-gpt-flow__kicker {
  color: #64748b;
}

.hydra-touch-gpt-flow.is-current {
  border-color: #fdba74;
  background: #fff7ed;
}

.hydra-touch-gpt-flow.is-cursor {
  border-color: #bfdbfe;
  background: #f8fafc;
}

.hydra-touch-gpt-flow.is-fail {
  border-color: #fecaca;
  background: #fff;
}

.hydra-touch-gpt-flow.is-cancel {
  border-color: #e2e8f0;
  background: #fff;
}

.hydra-touch-gpt-flow__kicker {
  margin: 0;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #94a3b8;
}

.hydra-touch-gpt-flow.is-current .hydra-touch-gpt-flow__kicker { color: #c2410c; }
.hydra-touch-gpt-flow.is-cursor .hydra-touch-gpt-flow__kicker { color: #1d4ed8; }
.hydra-touch-gpt-flow.is-fail .hydra-touch-gpt-flow__kicker { color: #b91c1c; }

.hydra-touch-gpt-flow__title {
  margin: 2px 0 0;
  font-size: 13px;
  font-weight: 800;
  color: #0f172a;
  min-width: 0;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.hydra-touch-gpt-flow__meta,
.hydra-touch-gpt-flow__auto {
  margin: 2px 0 0;
  font-size: 12px;
  font-weight: 650;
  min-width: 0;
  overflow-wrap: anywhere;
  color: #64748b;
}

.hydra-touch-gpt-flow .hydra-touch-primary {
  width: 100%;
  min-height: 44px;
  margin-top: 8px;
}

.hydra-touch-gpt-flow__link,
.hydra-touch-gpt-flow__fallback {
  margin-top: 6px;
  border: 0;
  background: transparent;
  padding: 0;
  min-height: 32px;
  font-size: 12px;
  font-weight: 800;
  color: #c2410c;
}

.hydra-touch-gpt-flow__fallback {
  display: block;
  color: #64748b;
}

.hydra-touch-gpt-flow-decision {
  margin: 10px 0 4px;
  font-size: 12px;
  font-weight: 700;
  color: #64748b;
}

.hydra-touch-gpt-flow-done {
  margin: 8px 0;
  padding: 8px 10px;
  border-radius: 12px;
  background: #f8fafc;
  color: #334155;
  font-size: 13px;
  font-weight: 800;
}

.hydra-touch-gpt-review.is-wait {
  border-style: dashed;
  background: #fff;
}

/* GPT → Cursor handoff journey (TASK-1330) */
.hydra-touch-gpt-journey {
  position: relative;
  margin: 10px 0 12px;
  padding: 2px 0 4px 16px;
  border-left: 2px solid #e2e8f0;
}

.hydra-touch-gpt-journey.is-solo {
  margin-top: 8px;
}

.hydra-touch-gpt-journey__preface {
  margin: 0 0 6px;
}

.hydra-touch-gpt-journey > .hydra-touch-gpt-flow,
.hydra-touch-gpt-journey > .hydra-touch-gpt-review,
.hydra-touch-gpt-journey > .hydra-touch-gpt-production,
.hydra-touch-gpt-journey > .hydra-touch-gpt-flow-done,
.hydra-touch-gpt-journey > .hydra-touch-gpt-flow-decision {
  position: relative;
}

.hydra-touch-gpt-journey > .hydra-touch-gpt-flow::after,
.hydra-touch-gpt-journey > .hydra-touch-gpt-review::after,
.hydra-touch-gpt-journey > .hydra-touch-gpt-production::after,
.hydra-touch-gpt-journey > .hydra-touch-gpt-flow-done::after,
.hydra-touch-gpt-journey > .hydra-touch-gpt-flow-decision::after {
  content: "";
  position: absolute;
  left: -21px;
  top: 13px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #fff;
  border: 2px solid #cbd5e1;
  box-sizing: border-box;
}

.hydra-touch-gpt-journey > .hydra-touch-gpt-flow.is-current::after {
  border-color: #ea580c;
  background: #fff7ed;
}

.hydra-touch-gpt-journey > .hydra-touch-gpt-flow.is-cursor::after,
.hydra-touch-gpt-journey > .hydra-touch-gpt-flow.is-running::after {
  border-color: #2563eb;
  background: #eff6ff;
}

.hydra-touch-gpt-journey > .hydra-touch-gpt-flow.is-queued::after {
  border-color: #64748b;
  background: #f8fafc;
}

.hydra-touch-gpt-journey > .hydra-touch-gpt-flow.is-fail::after {
  border-color: #dc2626;
  background: #fef2f2;
}

.hydra-touch-gpt-journey > .hydra-touch-gpt-flow.is-done::after {
  border-color: #16a34a;
  background: #f0fdf4;
}

.hydra-touch-gpt-journey > .hydra-touch-gpt-review.is-pass::after {
  border-color: #16a34a;
  background: #f0fdf4;
}

.hydra-touch-gpt-journey > .hydra-touch-gpt-review.is-fix::after {
  border-color: #ea580c;
  background: #fff7ed;
}

.hydra-touch-gpt-journey > .hydra-touch-gpt-review.is-check::after {
  border-color: #64748b;
  background: #f8fafc;
}

.hydra-touch-gpt-journey > .hydra-touch-gpt-review.is-pending::after {
  border-color: #94a3b8;
  background: #fff;
}

.hydra-touch-gpt-journey > .hydra-touch-gpt-review.is-error::after {
  border-color: #dc2626;
  background: #fef2f2;
}

.hydra-touch-gpt-journey > .hydra-touch-gpt-production::after {
  border-color: #475569;
  background: #f8fafc;
}

.hydra-touch-gpt-journey > .hydra-touch-gpt-flow-done::after {
  border-color: #334155;
  background: #f8fafc;
}

.hydra-touch-gpt-flow__row,
.hydra-touch-gpt-review__row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
  margin: 0 0 2px;
  min-width: 0;
}

.hydra-touch-gpt-flow__row .hydra-touch-gpt-flow__kicker,
.hydra-touch-gpt-review__row .hydra-touch-gpt-review__head {
  margin: 0;
  flex: 1 1 auto;
  min-width: 0;
}

.hydra-touch-gpt-flow__pill {
  flex: 0 0 auto;
  max-width: 46%;
  padding: 2px 7px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 800;
  line-height: 1.25;
  text-align: right;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.hydra-touch-gpt-flow__pill.is-muted {
  color: #64748b;
  background: #f1f5f9;
}

.hydra-touch-gpt-flow__pill.is-action {
  color: #9a3412;
  background: #ffedd5;
}

.hydra-touch-gpt-flow__pill.is-wait,
.hydra-touch-gpt-flow__pill.is-queued {
  color: #475569;
  background: #f1f5f9;
}

.hydra-touch-gpt-flow__pill.is-running {
  color: #1d4ed8;
  background: #dbeafe;
}

.hydra-touch-gpt-flow__pill.is-done {
  color: #15803d;
  background: #dcfce7;
}

.hydra-touch-gpt-flow__pill.is-fail {
  color: #b91c1c;
  background: #fee2e2;
}

.hydra-touch-gpt-flow__pill.is-pass {
  color: #15803d;
  background: #dcfce7;
}

.hydra-touch-gpt-flow__pill.is-fix {
  color: #c2410c;
  background: #ffedd5;
}

.hydra-touch-gpt-flow__pill.is-check {
  color: #475569;
  background: #f1f5f9;
}

.hydra-touch-gpt-flow.is-running {
  border-color: #93c5fd;
  background: #f8fafc;
}

.hydra-touch-gpt-flow.is-queued {
  border-style: dashed;
}

.hydra-touch-gpt-flow.is-done {
  border-color: #bbf7d0;
}

.hydra-touch-gpt-flow__status-note {
  margin: 6px 0 0;
  font-size: 11px;
  font-weight: 650;
  color: #64748b;
  line-height: 1.35;
}

.hydra-touch-gpt-wf-icon {
  display: inline-block;
  flex: 0 0 auto;
  width: 14px;
  height: 14px;
  margin-top: 1px;
  border-radius: 50%;
  border: 2px solid #cbd5e1;
  box-sizing: border-box;
  vertical-align: middle;
}

.hydra-touch-gpt-wf-icon.is-pass {
  border-color: #16a34a;
  background: #16a34a;
  box-shadow: inset 0 0 0 2px #fff;
}

.hydra-touch-gpt-wf-icon.is-fix {
  width: 0;
  height: 0;
  margin-top: 3px;
  border: none;
  border-left: 7px solid transparent;
  border-right: 7px solid transparent;
  border-bottom: 12px solid #ea580c;
  border-radius: 0;
  background: transparent;
}

.hydra-touch-gpt-wf-icon.is-check {
  border-color: #64748b;
  background: transparent;
}

.hydra-touch-gpt-wf-icon.is-fail {
  border-color: #dc2626;
  background: #dc2626;
  position: relative;
}

.hydra-touch-gpt-wf-icon.is-fail::before,
.hydra-touch-gpt-wf-icon.is-fail::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 8px;
  height: 2px;
  background: #fff;
  transform: translate(-50%, -50%) rotate(45deg);
}

.hydra-touch-gpt-wf-icon.is-fail::after {
  transform: translate(-50%, -50%) rotate(-45deg);
}

.hydra-touch-gpt-wf-icon.is-running {
  border-color: #2563eb;
  border-top-color: transparent;
  animation: hydra-touch-gpt-wf-spin 0.85s linear infinite;
}

.hydra-touch-gpt-wf-icon.is-dot {
  width: 8px;
  height: 8px;
  margin-top: 4px;
  border-width: 0;
  background: #cbd5e1;
}

.hydra-touch-gpt-review__verdict {
  display: flex;
  align-items: flex-start;
  gap: 8px;
}

.hydra-touch-gpt-review__verdict > span {
  min-width: 0;
}

.hydra-touch-gpt-review__visual-meta {
  margin: 0.25rem 0 0;
  font-size: 0.78rem;
  color: var(--hydra-muted, #64748b);
}

.hydra-touch-gpt-review__retry {
  display: block;
  margin-top: 8px;
  width: 100%;
  min-height: 40px;
  padding: 0 12px;
  border: 1px solid #fecaca;
  border-radius: 10px;
  background: #fff;
  font-size: 12px;
  font-weight: 800;
  color: #b91c1c;
  cursor: pointer;
}

.hydra-touch-gpt-review.is-running .hydra-touch-gpt-review__status::before {
  content: "";
  display: inline-block;
  width: 10px;
  height: 10px;
  margin-right: 6px;
  border: 2px solid #2563eb;
  border-top-color: transparent;
  border-radius: 50%;
  vertical-align: -1px;
  animation: hydra-touch-gpt-wf-spin 0.85s linear infinite;
}

.hydra-touch-gpt-production__steps li {
  display: flex;
  align-items: flex-start;
  gap: 8px;
}

.hydra-touch-gpt-production__steps .hydra-touch-gpt-wf-icon {
  margin-top: 2px;
}

.hydra-touch-gpt-production__verdict {
  display: flex;
  align-items: center;
  gap: 6px;
}

.hydra-touch-gpt-handoff-sheet__track {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 4px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.hydra-touch-gpt-handoff-sheet__track li {
  flex: 1 1 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  font-size: 10px;
  font-weight: 700;
  color: #94a3b8;
  text-align: center;
  line-height: 1.2;
}

.hydra-touch-gpt-handoff-sheet__track li.is-active {
  color: #c2410c;
}

.hydra-touch-gpt-handoff-sheet__dot {
  display: block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  border: 2px solid #cbd5e1;
  background: #fff;
  box-sizing: border-box;
}

.hydra-touch-gpt-handoff-sheet__track li.is-active .hydra-touch-gpt-handoff-sheet__dot {
  border-color: #ea580c;
  background: #fff7ed;
}

/* TASK-1332 — GPT Home push settings sheet */
.hydra-touch-gpt-bell-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.hydra-touch-gpt-bell-icon {
  display: block;
}

.hydra-touch-gpt-push-sheet__body {
  padding: 4px 16px 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-width: 0;
}

.hydra-touch-gpt-push-pill {
  margin: 0;
  align-self: flex-start;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  border: 1px solid #e2e8f0;
  background: #f8fafc;
  color: #475569;
}

.hydra-touch-gpt-push-pill.is-on {
  background: #ecfdf5;
  border-color: #a7f3d0;
  color: #047857;
}

.hydra-touch-gpt-push-pill.is-denied,
.hydra-touch-gpt-push-pill.is-unsupported {
  background: #fef2f2;
  border-color: #fecaca;
  color: #b91c1c;
}

.hydra-touch-gpt-push-pill.is-need-pwa {
  background: #fff7ed;
  border-color: #fed7aa;
  color: #c2410c;
}

.hydra-touch-gpt-push-copy,
.hydra-touch-gpt-push-busy {
  margin: 0;
  font-size: 13px;
  line-height: 1.45;
  color: #334155;
}

.hydra-touch-gpt-push-cta {
  width: 100%;
  min-height: 44px;
}

.hydra-touch-gpt-push-cta:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.hydra-touch-gpt-push-groups {
  margin: 0;
  padding: 0 0 0 18px;
  font-size: 12px;
  line-height: 1.5;
  color: #64748b;
}

.hydra-touch-gpt-push-groups li {
  margin: 0 0 4px;
}

@keyframes hydra-touch-gpt-wf-spin {
  to {
    transform: rotate(360deg);
  }
}

@media (prefers-reduced-motion: reduce) {
  .hydra-touch-gpt-wf-icon.is-running,
  .hydra-touch-gpt-review.is-running .hydra-touch-gpt-review__status::before,
  .hydra-touch-gpt-attach-slot__spin {
    animation: none;
    border-top-color: #2563eb;
  }

  .hydra-touch-gpt-attach-slot__spin {
    border-top-color: #f97316;
  }
}
