.nt-firstscreen {
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding-top: clamp(84px, 12vh, 140px);
  padding-bottom: clamp(36px, 6vh, 72px);
}

.nt-hero--center {
  text-align: center;
  padding: 0 0 clamp(18px, 2.5vw, 34px);
}
.nt-hero--center .nt-display .ln { display: inline-block; }

.nt-chat-section {
  padding: clamp(6px, 1.5vw, 18px) 0 0;
}

.nt-chat {
  max-width: 720px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
}

.nt-hero-mark {
  display: inline-block;
  width: 0.92em;
  margin-left: 0.12em;
  vertical-align: -0.1em;
  opacity: 1;
  animation: ntHeroFloat 4.6s ease-in-out infinite;
}

.nt-hero-mark img {
  display: block;
  width: 100%;
  height: auto;
  transform: translate(var(--hx, 0px), var(--hy, 0px)) rotate(var(--hr, -5deg));
  transition: transform 0.3s cubic-bezier(0.22, 1, 0.36, 1);
  filter: drop-shadow(0 10px 20px rgb(14 14 14 / 0.16));
}

@keyframes ntHeroFloat {
  0%,
  100% { transform: translateY(0); }
  50% { transform: translateY(-0.08em); }
}

.nt-chat-hello {
  text-align: center;
  margin: clamp(18px, 2.6vw, 28px) auto 0;
  max-width: 52ch;
}

.nt-chat-hello-sub {
  font-family: var(--sans);
  font-weight: 400;
  font-size: clamp(0.85rem, 1.2vw, 0.96rem);
  line-height: 1.66;
  color: rgb(from var(--ink) r g b / 0.46);
  margin: 0;
  text-wrap: pretty;
}

.nt-chat-hello-sub b {
  font-weight: 600;
  color: rgb(from var(--ink) r g b / 0.7);
}

.nt-chat.is-open .nt-chat-hello {
  display: none;
}

.nt-contact .nt-end {
  font-size: clamp(2.6rem, 6.5vw, 5.5rem);
  margin-bottom: clamp(18px, 2.5vw, 30px);
}

.nt-end-sub {
  font-family: var(--zh);
  font-weight: 500;
  font-size: clamp(1.05rem, 1.7vw, 1.4rem);
  line-height: 1.5;
  color: rgb(255 255 255 / 0.72);
  max-width: 52ch;
  margin: 0 0 var(--sp-lg);
  text-wrap: pretty;
}

.nt-chat-log {
  display: none;
  flex-direction: column;
  gap: 22px;
}

.nt-chat.is-open .nt-chat-log {
  display: flex;
  height: clamp(320px, 46vh, 500px);
  overflow-y: auto;
  padding: 4px 4px 26px;
  margin-bottom: 22px;
  animation: ntOpen 0.5s cubic-bezier(0.22, 1, 0.36, 1) both;
}

@keyframes ntOpen {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.nt-msg {
  display: flex;
  flex-direction: column;
  gap: 6px;
  max-width: 82%;
}

.nt-msg .meta {
  font-family: var(--display);
  font-weight: 700;
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgb(from var(--ink) r g b / 0.4);
}

.nt-msg .bubble {
  font-family: var(--zh);
  font-weight: 400;
  font-size: 1.02rem;
  line-height: 1.62;
  padding: 14px 17px;
  white-space: pre-wrap;
  text-wrap: pretty;
  border-radius: 16px;
}

.nt-msg.agent {
  align-self: flex-start;
}

.nt-msg.agent .meta {
  color: var(--brand);
}

.nt-msg.agent .bubble {
  background: var(--light);
  color: var(--ink);
  border-bottom-left-radius: 4px;
}

.nt-msg.user {
  align-self: flex-end;
  align-items: flex-end;
}

.nt-msg.user .bubble {
  background: var(--ink);
  color: #fff;
  border-bottom-right-radius: 4px;
}

.nt-msg.enter {
  animation: ntMsgIn 0.38s cubic-bezier(0.22, 1, 0.36, 1) both;
}

@keyframes ntMsgIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.nt-typing {
  display: inline-flex;
  gap: 5px;
  padding: 16px 17px;
  background: var(--light);
  border-radius: 16px 16px 16px 4px;
}

.nt-typing span {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: rgb(from var(--ink) r g b / 0.4);
  animation: ntType 1.2s ease-in-out infinite;
}

.nt-typing span:nth-child(2) {
  animation-delay: 0.18s;
}

.nt-typing span:nth-child(3) {
  animation-delay: 0.36s;
}

@keyframes ntType {
  0%,
  60%,
  100% {
    transform: translateY(0);
    opacity: 0.4;
  }
  30% {
    transform: translateY(-5px);
    opacity: 1;
  }
}

.nt-composer-card {
  position: relative;
  margin-top: 0;
  border: 1px solid var(--ink);
  border-radius: 20px;
  background: var(--bg);
  box-shadow: 0 12px 38px rgb(14 14 14 / 0.09);
}

.nt-chat-compose {
  display: flex;
  align-items: flex-end;
  gap: 10px;
  padding: 10px 10px 10px 12px;
}

.nt-chat-input {
  flex: 1;
  min-width: 0;
  font-family: var(--zh);
  font-weight: 400;
  font-size: 1.08rem;
  line-height: 1.5;
  color: var(--ink);
  background: transparent;
  border: none;
  outline: none;
  resize: none;
  max-height: 160px;
  padding: 12px 0;
}

.nt-chat-input::placeholder {
  color: rgb(from var(--ink) r g b / 0.4);
}

.nt-chat-send {
  flex: 0 0 auto;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: var(--brand);
  color: #fff;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.25s, background 0.25s;
}

.nt-chat-send svg {
  width: 22px;
  height: 22px;
}

.nt-chat-send:hover {
  transform: translateY(-2px) scale(1.06);
}

.nt-chat-send:disabled {
  opacity: 0.28;
  cursor: default;
  transform: none;
}

.nt-attach {
  flex: 0 0 auto;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: transparent;
  border: 1px solid rgb(from var(--ink) r g b / 0.2);
  color: rgb(from var(--ink) r g b / 0.55);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color 0.2s, color 0.2s, transform 0.2s;
}

.nt-attach svg {
  width: 19px;
  height: 19px;
}

.nt-attach:hover {
  border-color: var(--brand);
  color: var(--brand);
  transform: translateY(-1px);
}

.nt-attach-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 14px 16px 0;
}

.nt-attach-list[hidden] {
  display: none;
}

.nt-attach-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  max-width: 240px;
  border: 1px solid rgb(from var(--ink) r g b / 0.18);
  border-radius: 10px;
  padding: 7px 8px 7px 12px;
  background: var(--light);
}

.nt-attach-pill .nm {
  font-family: var(--sans);
  font-size: 0.82rem;
  color: var(--ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.nt-attach-pill .rm {
  flex: 0 0 auto;
  width: 18px;
  height: 18px;
  border: none;
  background: rgb(from var(--ink) r g b / 0.1);
  color: var(--ink);
  border-radius: 50%;
  cursor: pointer;
  font-size: 13px;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
}

.nt-attach-pill .rm:hover {
  background: var(--brand);
  color: #fff;
}

.nt-chat-foot {
  text-align: center;
  font-family: var(--sans);
  font-weight: 400;
  font-size: 12px;
  line-height: 1.6;
  color: rgb(from var(--ink) r g b / 0.45);
  margin: 22px auto 0;
}

.nt-chat-foot a {
  color: var(--brand);
  border-bottom: 1px solid currentColor;
}

.nt-agent {
  width: 74px;
  height: 74px;
  margin: 0 auto clamp(20px, 3vw, 30px);
  position: relative;
  z-index: 6;
  pointer-events: none;
}

.nt-agent-float {
  animation: ntFloat 4.2s ease-in-out infinite;
}

@keyframes ntFloat {
  0%,
  100% { transform: translateY(0); }
  50% { transform: translateY(-7px); }
}

.nt-agent-head {
  width: 100%;
  height: auto;
  display: block;
  transform: translate(var(--lx, 0px), var(--ly, 0px)) rotate(var(--lr, 0deg));
  transition: transform 0.28s cubic-bezier(0.22, 1, 0.36, 1);
  filter: drop-shadow(0 10px 18px rgb(14 14 14 / 0.16));
  will-change: transform;
}

#chat.is-listening .nt-agent-head {
  --ly: 6px;
  --lr: 0deg;
}

#chat.is-thinking .nt-agent-head {
  animation: ntThink 1s ease-in-out infinite;
}

@keyframes ntThink {
  0%,
  100% { transform: translate(var(--lx, 0px), var(--ly, 0px)) rotate(-8deg); }
  50% { transform: translate(var(--lx, 0px), var(--ly, 0px)) rotate(8deg); }
}

#chat.is-replied .nt-agent-head {
  animation: ntPop 0.7s cubic-bezier(0.22, 1.4, 0.4, 1);
}

@keyframes ntPop {
  0% { transform: translateY(0) scale(1); }
  35% { transform: translateY(-14px) scale(1.1); }
  100% { transform: translateY(0) scale(1); }
}

.nt-way:hover .nt-swap .a {
  transform: translateY(-100%);
}

.nt-way:hover .nt-swap .b {
  transform: translateY(0);
}

.nt-sechead--sm {
  font-size: clamp(2.6rem, 6.5vw, 5.5rem);
  padding-top: var(--sp-xl);
  padding-bottom: var(--sp-2xs);
}

.nt-way p em {
  font-style: normal;
  color: var(--brand);
}

.nt-sechead-sub {
  font-family: var(--zh);
  font-weight: 600;
  font-size: clamp(1.1rem, 1.9vw, 1.6rem);
  line-height: 1.5;
  letter-spacing: -0.01em;
  color: rgb(from var(--ink) r g b / 0.55);
  margin: 10px 0 var(--sp-lg);
  max-width: 60ch;
  text-wrap: pretty;
}

@media (max-width: 680px) {
  .nt-msg {
    max-width: 90%;
  }

  .nt-agent {
    width: 64px;
    height: 64px;
  }

  .nt-chat-compose {
    gap: 8px;
  }

  .nt-chat-input {
    font-size: 1rem;
    min-height: 4.5em; /* 容纳两行占位文案,移动端不再被截断 */
  }
}

@media (prefers-reduced-motion: reduce) {
  .nt-hero-mark,
  .nt-agent-float,
  #chat.is-thinking .nt-agent-head,
  #chat.is-replied .nt-agent-head,
  .nt-msg.enter,
  .nt-chat.is-open .nt-chat-log {
    animation: none;
  }
}
