body[data-theme] {
  width: 100%;
  height: 100%;
  margin: 0;
  overflow: hidden;
  background: var(--paper);
  color: var(--ink);
}

button,
textarea,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

.agent-app {
  min-width: 1120px;
  min-height: 650px;
  width: 100vw;
  height: 100vh;
  display: grid;
  grid-template-rows: 76px minmax(0, 1fr);
  background: var(--paper);
}

.agent-header {
  z-index: 200;
  display: grid;
  grid-template-columns: 360px minmax(0, 1fr) 262px;
  align-items: center;
  gap: 18px;
  padding: 0 26px;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.98);
}

.agent-brand {
  display: flex;
  align-items: center;
  gap: 13px;
  min-width: 0;
  color: inherit;
  text-decoration: none;
  border-radius: var(--r-sm);
  transition: background 160ms ease;
}

a.agent-brand:hover {
  background: var(--canvas);
}

a.agent-brand:hover strong {
  color: var(--ink-fill);
}

.agent-brand img {
  width: 44px;
  height: 44px;
  object-fit: contain;
}

.agent-brand div {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.agent-brand strong {
  font-size: 20px;
  line-height: 1.1;
  white-space: nowrap;
}

.agent-brand span {
  color: var(--muted);
  font-size: 12px;
}

.agent-nav {
  height: 100%;
  display: flex;
  justify-content: center;
  gap: 2px;
}

.agent-nav a {
  position: relative;
  min-width: 128px;
  height: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 0 12px;
  color: var(--ink-soft);
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
}

.agent-nav a b {
  color: #817f7c;
  font-size: 12px;
}

.agent-nav a::after {
  content: "";
  position: absolute;
  right: 20px;
  bottom: 0;
  left: 20px;
  height: 3px;
  background: transparent;
}

.agent-nav a.active {
  color: var(--crimson-deep);
}

.agent-nav a.active b {
  color: var(--crimson-deep);
}

.agent-nav a.active::after {
  background: var(--crimson);
}

.agent-header > .header-actions {
  grid-column: 3;
}

.header-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
}

.scene-clock {
  color: #817f7c;
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 12px;
}

body.mode-manual .scene-clock {
  display: none;
}

.mode-toggle {
  display: inline-flex;
  padding: 3px;
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  background: var(--canvas);
}

.mode-toggle button {
  height: 30px;
  padding: 0 13px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  border: 0;
  border-radius: var(--r-sm);
  background: transparent;
  color: var(--ink-soft);
  font-size: 12px;
  font-weight: 800;
  transition:
    background 150ms ease,
    color 150ms ease,
    box-shadow 150ms ease;
}

.mode-toggle button.active {
  background: white;
  color: var(--crimson-deep);
  box-shadow: 0 1px 3px rgba(34, 33, 32, 0.14);
}

.settings-pod {
  position: relative;
}

.settings-button {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  background: white;
  color: var(--ink-soft);
  font-size: 19px;
  line-height: 1;
  transition:
    background 150ms ease,
    color 150ms ease,
    border-color 150ms ease;
}

.settings-button:hover,
.settings-button[aria-expanded="true"] {
  border-color: var(--crimson);
  background: var(--canvas);
  color: var(--crimson-deep);
}

.shell-icon,
.send-prompt svg {
  display: block;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.shell-icon {
  width: 19px;
  height: 19px;
  stroke-width: 1.6;
}
.send-prompt svg {
  width: 17px;
  height: 17px;
  stroke-width: 2;
}

.agent-info-button {
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  background: white;
  color: var(--ink-soft);
  font-size: 12px;
  font-weight: 850;
  white-space: nowrap;
  transition:
    background 150ms ease,
    color 150ms ease,
    border-color 150ms ease,
    transform 150ms ease;
}

.agent-info-button i {
  width: 18px;
  height: 18px;
  display: grid;
  place-items: center;
  border: 1.5px solid currentColor;
  border-radius: 50%;
  font-family: Georgia, serif;
  font-size: 12px;
  font-style: normal;
  font-weight: 900;
  line-height: 1;
}

.agent-info-button:hover,
.agent-info-button[aria-expanded="true"] {
  border-color: var(--ink-fill);
  background: var(--canvas);
  color: var(--ink-fill);
  transform: translateY(-1px);
}

.agent-info-backdrop {
  position: fixed;
  z-index: 200;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 32px;
  overflow: hidden;
  background: rgba(34, 33, 32, 0.58);
  opacity: 0;
  backdrop-filter: blur(7px);
  transition: opacity 180ms ease;
}

.agent-info-backdrop[hidden] {
  display: none;
}

.agent-info-backdrop.open {
  opacity: 1;
}

.agent-info-dialog {
  position: relative;
  width: min(1040px, calc(100vw - 64px));
  max-height: calc(100vh - 64px);
  padding: 34px 38px 30px;
  overflow: auto;
  border: 1px solid color-mix(in srgb, var(--ink-fill) 25%, var(--line));
  border-radius: var(--r-md);
  outline: none;
  background: #fff;
  box-shadow: 0 34px 90px rgba(34, 33, 32, 0.3);
  opacity: 0;
  transform: translateY(14px) scale(0.985);
  transition:
    opacity 190ms ease,
    transform 190ms ease;
}

.agent-info-backdrop.open .agent-info-dialog {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.agent-info-close {
  position: absolute;
  z-index: 2;
  top: 20px;
  right: 22px;
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.9);
  color: var(--ink-soft);
  font-size: 25px;
  line-height: 1;
}

.agent-info-close:hover,
.agent-info-close:focus-visible {
  border-color: var(--ink-fill);
  color: var(--ink-fill);
}

.agent-info-head {
  padding-right: 54px;
}

.agent-info-head > p {
  margin: 0 0 7px;
  color: var(--ink-fill);
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 0.08em;
}

.agent-info-head h2 {
  margin: 0;
  color: var(--ink);
  font-family: Georgia, "Songti SC", serif;
  font-size: 38px;
  line-height: 1.15;
}

.agent-info-head > div {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 9px;
  color: var(--ink-soft);
  font-size: 15px;
  font-weight: 750;
}

.agent-info-head > div i {
  width: 1px;
  height: 14px;
  background: var(--line);
}

.agent-info-head > strong {
  display: block;
  margin-top: 18px;
  padding: 14px 16px;
  border-left: 4px solid var(--ink-fill);
  background: var(--canvas);
  color: var(--ink-soft);
  font-size: 17px;
  line-height: 1.55;
}

.agent-info-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.04fr) minmax(0, 0.96fr);
  gap: 22px;
  margin-top: 22px;
}

.agent-info-grid section {
  min-width: 0;
  padding: 20px 22px;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background: rgba(255, 255, 255, 0.9);
}

.agent-info-grid h3,
.agent-info-watch h3 {
  margin: 0 0 12px;
  color: var(--ink);
  font-size: 18px;
  line-height: 1.3;
}

.agent-info-grid h3 span {
  display: inline-flex;
  margin-right: 8px;
  padding: 4px 7px;
  border-radius: var(--r-sm);
  background: var(--ink-fill);
  color: white;
  font-size: 11px;
  letter-spacing: 0.04em;
  vertical-align: 2px;
}

.agent-info-grid p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 16px;
  line-height: 1.72;
}

.agent-info-grid p + p {
  margin-top: 10px;
}

.agent-info-script {
  border-top: 4px solid var(--ink-fill) !important;
  background: color-mix(in srgb, var(--canvas) 52%, white) !important;
}

.agent-info-watch {
  margin-top: 22px;
}

.agent-info-watch ol {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.agent-info-watch li {
  min-width: 0;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  align-items: start;
  gap: 10px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background: white;
}

.agent-info-watch li b {
  color: var(--ink-fill);
  font-family: Georgia, serif;
  font-size: 20px;
}

.agent-info-watch li span {
  color: var(--ink-soft);
  font-size: 14px;
  line-height: 1.5;
}

.agent-info-hook {
  display: grid;
  grid-template-columns: 104px minmax(0, 1fr);
  align-items: center;
  gap: 14px;
  margin-top: 18px;
  padding: 13px 16px;
  border-radius: var(--r-md);
  background: var(--ink);
}

.agent-info-hook span {
  color: #817f7c;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.08em;
}

.agent-info-hook p {
  margin: 0;
  color: white;
  font-size: 15px;
  font-weight: 750;
  line-height: 1.5;
}

.settings-menu {
  position: absolute;
  z-index: 60;
  top: 46px;
  right: 0;
  width: 230px;
  display: grid;
  gap: 12px;
  padding: 15px;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background: white;
  box-shadow: 0 20px 48px rgba(34, 33, 32, 0.18);
}

.settings-menu[hidden] {
  display: none;
}

.settings-title {
  margin: 0;
  color: #817f7c;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.04em;
}

.settings-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  font-size: 12px;
  font-weight: 700;
  color: var(--ink-soft);
}

body.mode-manual .settings-item.clock-row {
  display: none;
}

.settings-menu .scene-clock {
  display: inline;
}

.settings-menu .replay-button {
  width: 100%;
  height: 38px;
  gap: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 800;
  color: var(--ink-fill);
  border-color: color-mix(in srgb, var(--ink-fill) 35%, var(--line));
}

.settings-menu .replay-button:hover {
  background: var(--canvas);
}

.replay-button {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  background: white;
  color: var(--ink-soft);
  font-size: 21px;
}

.agent-main {
  min-height: 0;
  display: grid;
  grid-template-columns: 390px minmax(0, 1fr);
}

.prompt-panel {
  position: relative;
  z-index: 4;
  min-height: 0;
  display: flex;
  flex-direction: column;
  padding: 24px 24px 22px;
  overflow: hidden;
  border-right: 1px solid var(--line);
  background: var(--canvas);
}

.teacher-row {
  display: grid;
  grid-template-columns: 48px 1fr auto;
  align-items: center;
  gap: 12px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--line);
}

.teacher-avatar {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--ink-fill);
  color: white;
  font-size: 17px;
  font-weight: 900;
}

.teacher-row div {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.teacher-row strong {
  font-size: 16px;
}

.teacher-row .course-label {
  color: var(--ink-fill);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.08em;
}

.teacher-row .course-name {
  overflow: hidden;
  color: var(--ink);
  font-size: 24px;
  line-height: 1.08;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.teacher-row small {
  overflow: hidden;
  color: var(--muted);
  font-size: 13px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.online {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--crimson-deep);
  font-size: 12px;
  font-weight: 700;
}

.online::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--crimson);
}

.prompt-label {
  margin: 24px 0 10px;
  color: #817f7c;
  font-size: 13px;
  font-weight: 900;
}

.prompt-field {
  min-height: 190px;
  padding: 18px 18px;
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  background: white;
  color: var(--ink);
  font-size: 20px;
  line-height: 1.7;
  box-shadow: inset 0 1px 0 rgba(34, 33, 32, 0.03);
}

.typed-prompt:empty::before {
  content: "请描述需要生成的教学内容或可视化实验……";
  color: #817f7c;
}

.typing-caret {
  display: none;
  width: 2px;
  height: 23px;
  margin-left: 2px;
  vertical-align: -4px;
  background: var(--ink-fill);
  animation: caret 0.65s steps(1) infinite;
}

body.is-typing .typing-caret {
  display: inline-block;
}

@keyframes caret {
  50% {
    opacity: 0;
  }
}

.send-prompt {
  height: 48px;
  margin-top: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border: 0;
  border-radius: var(--r-sm);
  background: var(--crimson);
  color: white;
  font-size: 15px;
  font-weight: 850;
  transition:
    transform 160ms ease,
    box-shadow 160ms ease;
}

.send-prompt.clicked {
  transform: scale(0.985);
  box-shadow: 0 0 0 5px rgba(184, 41, 52, 0.17);
}

.prompt-summary {
  min-height: 64px;
  margin-top: 18px;
  padding: 12px 14px;
  border-left: 3px solid var(--ink-fill);
  background: var(--canvas);
  color: var(--ink-soft);
  font-size: 14px;
  line-height: 1.65;
  opacity: 0;
  transform: translateY(8px);
  transition:
    opacity 320ms ease,
    transform 320ms ease;
}

body.result-ready .prompt-summary {
  opacity: 1;
  transform: translateY(0);
}

.prompt-summary strong {
  display: block;
  margin-bottom: 2px;
  color: var(--ink-fill);
  font-size: 14px;
}

.progress-block {
  margin-top: auto;
  padding-top: 20px;
}

.progress-head {
  display: flex;
  justify-content: space-between;
  margin-bottom: 14px;
  color: #817f7c;
  font-size: 12px;
  font-weight: 800;
}

.progress-head span:last-child {
  color: var(--crimson-deep);
}

.progress-orbs {
  position: relative;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 4px;
}

.progress-orbs::before {
  content: "";
  position: absolute;
  top: 18px;
  right: 11%;
  left: 11%;
  height: 2px;
  background: var(--line);
}

.progress-node {
  position: relative;
  z-index: 2;
  display: grid;
  justify-items: center;
  gap: 8px;
  color: #817f7c;
  font-size: 12px;
  text-align: center;
}

.progress-node i {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border: 2px solid var(--line);
  border-radius: 50%;
  background: var(--canvas);
  color: #817f7c;
  font-size: 12px;
  font-style: normal;
  font-weight: 900;
  transition: all 300ms ease;
}

.progress-node.active i {
  border-color: var(--crimson);
  background: white;
  color: var(--crimson-deep);
  box-shadow: 0 0 0 6px rgba(184, 41, 52, 0.1);
  animation: node-pulse 1s ease-in-out infinite;
}

.progress-node.done {
  color: var(--ink-soft);
}

.progress-node.done i {
  border-color: var(--ink-fill);
  background: var(--ink-fill);
  color: white;
  box-shadow: none;
  animation: none;
}

@keyframes node-pulse {
  50% {
    transform: scale(1.08);
  }
}

.result-workspace {
  min-width: 0;
  min-height: 0;
  display: grid;
  grid-template-rows: 54px minmax(0, 1fr);
  padding: 0 24px 22px;
  overflow: hidden;
  background: var(--canvas);
}

.workspace-titlebar {
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.workspace-titlebar > div:first-child {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 9px;
}

.workspace-live {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--crimson);
  box-shadow: 0 0 0 5px rgba(184, 41, 52, 0.1);
}

.workspace-titlebar strong {
  color: var(--ink);
  font-size: 19px;
}

.workspace-titlebar small {
  overflow: hidden;
  color: var(--muted);
  font-size: 13px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.workspace-badge {
  padding: 6px 9px;
  border: 1px solid color-mix(in srgb, var(--ink-fill) 25%, var(--line));
  border-radius: var(--r-sm);
  background: white;
  color: var(--ink-fill);
  font-size: 12px;
  font-weight: 900;
}

.lab-frame {
  position: relative;
  min-width: 0;
  min-height: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background: white;
  box-shadow: none;
}

.build-overlay {
  position: absolute;
  z-index: 30;
  inset: 0;
  display: grid;
  place-items: center;
  background: var(--canvas);
  transition:
    opacity 520ms ease,
    visibility 520ms ease;
}

.build-animation {
  display: grid;
  justify-items: center;
  gap: 13px;
}

.build-animation > span {
  position: relative;
  width: 60px;
  height: 60px;
  border: 3px solid var(--line);
  border-top-color: var(--crimson);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

.build-animation > span::after {
  content: "∑";
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: var(--ink-fill);
  font-family: Georgia, serif;
  font-size: 20px;
  font-weight: 800;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.build-animation strong {
  font-size: 16px;
}

.build-animation small {
  color: var(--muted);
  font-size: 13px;
}

body.result-ready .build-overlay {
  visibility: hidden;
  opacity: 0;
}

.lab-content {
  width: 100%;
  height: 100%;
  opacity: 0;
  transform: scale(0.99);
  transition:
    opacity 600ms ease,
    transform 600ms ease;
}

body.result-ready .lab-content {
  opacity: 1;
  transform: scale(1);
}

.demo-pointer {
  position: absolute;
  z-index: 50;
  top: 24%;
  left: 76%;
  width: 24px;
  height: 32px;
  opacity: 0;
  pointer-events: none;
  filter: drop-shadow(0 2px 2px rgba(0, 0, 0, 0.22));
  transition:
    top 520ms cubic-bezier(0.32, 0.72, 0.26, 1),
    left 520ms cubic-bezier(0.32, 0.72, 0.26, 1),
    opacity 180ms ease;
}

.demo-pointer::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 0;
  height: 0;
  border-top: 23px solid var(--night);
  border-right: 15px solid transparent;
  transform: rotate(-16deg);
}

.demo-pointer::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 0;
  height: 0;
  border-top: 16px solid white;
  border-right: 10px solid transparent;
  transform: rotate(-16deg);
}

.demo-pointer span {
  position: absolute;
  top: -13px;
  left: -13px;
  width: 39px;
  height: 39px;
  border: 2px solid color-mix(in srgb, var(--ink-fill) 60%, transparent);
  border-radius: 50%;
  opacity: 0;
}

.demo-pointer.visible {
  opacity: 1;
}

.demo-pointer.clicking span {
  animation: pointer-click 620ms ease-out;
}

@keyframes pointer-click {
  0% {
    opacity: 0;
    transform: scale(0.45);
  }
  35% {
    opacity: 1;
  }
  100% {
    opacity: 0;
    transform: scale(1.5);
  }
}

body.record-mode .agent-nav,
body.record-mode .header-actions {
  visibility: hidden;
}

body.presentation-mode .agent-header {
  grid-template-columns: minmax(0, 1fr);
  background: #fff;
  isolation: isolate;
  transform: translateZ(0);
}

body.presentation-mode .agent-header > :not(.agent-brand) {
  display: none;
}

/* PPT/GIF 录制时由外层幻灯片承担标题，网页内部不再重复顶部品牌栏。 */
body.capture-mode .agent-app {
  grid-template-rows: minmax(0, 1fr);
}

body.capture-mode .agent-header {
  display: none;
}

@media (max-width: 1450px), (max-height: 820px) {
  .agent-app {
    grid-template-rows: 64px minmax(0, 1fr);
  }

  .agent-header {
    grid-template-columns: 330px minmax(0, 1fr) 140px;
    padding: 0 18px;
  }

  body.presentation-mode .agent-header {
    grid-template-columns: minmax(0, 1fr);
  }

  .agent-brand img {
    width: 38px;
    height: 38px;
  }

  .agent-brand strong {
    font-size: 17px;
  }

  .agent-nav a {
    min-width: 108px;
    font-size: 12px;
  }

  .agent-main {
    grid-template-columns: 330px minmax(0, 1fr);
  }

  .prompt-panel {
    padding: 16px 18px;
  }

  .teacher-row .course-name {
    font-size: 21px;
  }

  .prompt-label {
    margin-top: 15px;
  }

  .prompt-field {
    min-height: 145px;
    padding: 14px;
    font-size: 16px;
  }

  .send-prompt {
    height: 40px;
  }

  .prompt-summary {
    margin-top: 11px;
    min-height: 54px;
    padding: 9px 11px;
    font-size: 12px;
  }

  .progress-block {
    padding-top: 12px;
  }

  .progress-node i {
    width: 32px;
    height: 32px;
  }

  .progress-orbs::before {
    top: 15px;
  }

  .result-workspace {
    grid-template-rows: 46px minmax(0, 1fr);
    padding: 0 16px 14px;
  }
}

@media (max-height: 820px) {
  .agent-info-backdrop {
    padding: 18px;
  }

  .agent-info-dialog {
    width: min(980px, calc(100vw - 36px));
    max-height: calc(100vh - 36px);
    padding: 24px 28px 22px;
  }

  .agent-info-close {
    top: 14px;
    right: 16px;
    width: 34px;
    height: 34px;
  }

  .agent-info-head h2 {
    font-size: 31px;
  }

  .agent-info-head > strong {
    margin-top: 12px;
    padding: 10px 13px;
    font-size: 14px;
  }

  .agent-info-grid {
    gap: 14px;
    margin-top: 14px;
  }

  .agent-info-grid section {
    padding: 14px 16px;
  }

  .agent-info-grid h3,
  .agent-info-watch h3 {
    margin-bottom: 8px;
    font-size: 15px;
  }

  .agent-info-grid p {
    font-size: 13.5px;
    line-height: 1.58;
  }

  .agent-info-watch {
    margin-top: 14px;
  }

  .agent-info-watch li {
    padding: 10px;
  }

  .agent-info-watch li span {
    font-size: 12.5px;
  }

  .agent-info-hook {
    margin-top: 12px;
    padding: 10px 13px;
  }

  .agent-info-hook p {
    font-size: 13px;
  }
}

@media (max-width: 1100px) {
  .agent-info-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .agent-info-watch ol {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 760px) {
  body[data-theme] {
    overflow: auto;
  }

  .agent-app {
    min-width: 320px;
    min-height: 100vh;
    min-height: 100dvh;
    height: auto;
    grid-template-rows: 64px auto;
  }

  .agent-header {
    position: sticky;
    top: 0;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px;
    padding: 0 14px;
  }

  .agent-brand {
    gap: 9px;
  }
  .agent-brand img {
    width: 36px;
    height: 36px;
  }
  .agent-brand strong {
    font-size: 15px;
  }
  .agent-brand span,
  .agent-nav {
    display: none;
  }
  .agent-header > .header-actions {
    grid-column: 2;
  }

  .agent-main {
    min-width: 0;
    grid-template-columns: minmax(0, 1fr);
  }

  .prompt-panel {
    min-height: calc(100vh - 64px);
    min-height: calc(100dvh - 64px);
    padding: 18px 20px 22px;
    overflow: visible;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .result-workspace {
    min-height: 760px;
    grid-template-rows: auto minmax(680px, 1fr);
    padding: 0 12px 12px;
  }

  .workspace-titlebar {
    min-height: 64px;
    align-items: flex-start;
    flex-direction: column;
    justify-content: center;
    gap: 3px;
  }

  .workspace-titlebar > div:first-child {
    flex-wrap: wrap;
  }
  .workspace-titlebar strong {
    font-size: 16px;
  }
  .workspace-titlebar small {
    width: 100%;
    padding-left: 17px;
  }
  .workspace-badge {
    display: none;
  }

  .lab-frame {
    overflow: auto;
  }
  .lab-content {
    min-width: 960px;
    min-height: 650px;
  }

  .agent-info-button {
    width: 38px;
    padding: 0;
  }

  .agent-info-button span {
    display: none;
  }

  .agent-info-backdrop {
    padding: 10px;
  }

  .agent-info-dialog {
    width: calc(100vw - 20px);
    max-height: calc(100vh - 20px);
    padding: 22px 18px 18px;
  }

  .agent-info-head {
    padding-right: 36px;
  }

  .agent-info-head h2 {
    font-size: 27px;
  }

  .agent-info-head > div {
    align-items: flex-start;
    flex-direction: column;
    gap: 3px;
  }

  .agent-info-head > div i {
    display: none;
  }

  .agent-info-hook {
    grid-template-columns: minmax(0, 1fr);
    gap: 4px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
