:root {
  --ink: #10130f;
  --ink-soft: #171b17;
  --paper: #f1f0e9;
  --paper-2: #e7e5dc;
  --paper-dim: #b8bbb3;
  --muted: #6f756e;
  --acid: #c9f43d;
  --acid-ink: #4b6200;
  --line: rgba(16, 19, 15, .18);
  --line-light: rgba(241, 240, 233, .2);
  --font-sans: "Bricolage Grotesque", "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
  --font-serif: "Instrument Serif", Georgia, serif;
  --font-serif-zh: "Songti SC", "STSong", "Noto Serif CJK SC", serif;
  --font-mono: "DM Mono", "PingFang SC", "Microsoft YaHei", monospace;
  --shell: min(1380px, calc(100vw - 72px));
}

* { box-sizing: border-box; }
html { background: var(--paper); scroll-behavior: smooth; }
body { min-width: 320px; margin: 0; color: var(--ink); background: var(--paper); font-family: var(--font-sans); -webkit-font-smoothing: antialiased; }
html[lang^="zh"] body { font-feature-settings: "kern"; }
html[lang^="zh"] h1 em,
html[lang^="zh"] h2 em { font-family: var(--font-serif-zh); font-style: normal; letter-spacing: -.045em; }
html[lang^="zh"] .hero h1 { letter-spacing: -.065em; line-height: 1.02; }
html[lang^="zh"] .hero-intro,
html[lang^="zh"] .chat-heading > p,
html[lang^="zh"] .message-copy,
html[lang^="zh"] .case-body > p:last-child,
html[lang^="zh"] .system-list p,
html[lang^="zh"] .skill-copy > p:not(.eyebrow) { line-height: 1.78; }
html[lang^="zh"] .eyebrow,
html[lang^="zh"] .hero-location,
html[lang^="zh"] .prompt-chip,
html[lang^="zh"] .chat-status,
html[lang^="zh"] .case-topline,
html[lang^="zh"] .case-footer { letter-spacing: .015em; }
body::selection { color: var(--ink); background: var(--acid); }
a { color: inherit; text-decoration: none; }
button, textarea { font: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 2px solid var(--acid-ink); outline-offset: 4px; }
.chat-shell :focus-visible, .skill-window :focus-visible { outline-color: var(--acid); }
.shell { width: var(--shell); margin-inline: auto; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); clip-path: inset(50%); white-space: nowrap; }
.page-noise { position: fixed; z-index: 20; inset: 0; pointer-events: none; opacity: .025; background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 160 160' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.78' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E"); }

.site-header { display: flex; height: 76px; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--line); }
.brand { display: inline-flex; align-items: center; gap: 10px; font-size: 14px; font-weight: 700; letter-spacing: -.04em; }
.brand-mark { display: block; width: 28px; height: 28px; flex: 0 0 auto; overflow: hidden; background: var(--acid); }
.brand-mark img { display: block; width: 100%; height: 100%; object-fit: cover; transform: scale(1.16); }
.desktop-nav { display: flex; gap: 30px; margin-left: 100px; }
.desktop-nav a, .nav-chat { color: var(--muted); font-family: var(--font-mono); font-size: 11px; letter-spacing: .04em; text-transform: uppercase; transition: color .2s ease; }
.desktop-nav a:hover, .nav-chat:hover { color: var(--ink); }
.nav-chat { display: inline-flex; align-items: center; gap: 8px; color: var(--ink); }
.header-actions { display: flex; align-items: center; gap: 22px; }
.language-switcher { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); font-family: var(--font-mono); font-size: 10px; letter-spacing: .035em; white-space: nowrap; }
.language-switcher span[aria-current="true"] { color: var(--ink); font-weight: 500; }
.language-switcher i { color: rgba(16, 19, 15, .35); font-style: normal; }
.language-switcher a { transition: color .2s ease; }
.language-switcher a:hover { color: var(--ink); }
.status-dot { display: inline-block; width: 6px; height: 6px; flex: 0 0 auto; border-radius: 50%; background: var(--acid); box-shadow: 0 0 10px rgba(201, 244, 61, .7); animation: blink 2.6s ease-in-out infinite; }

.hero { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) 248px; min-height: min(720px, calc(100svh - 76px)); gap: clamp(48px, 8vw, 120px); align-items: center; overflow: hidden; padding: clamp(70px, 9vw, 116px) 0 72px; }
.hero-grid { display: none; }
.hero-copy, .hero-portrait-wrap, .hero-note { position: relative; z-index: 1; }
.hero-copy { max-width: 900px; }
.eyebrow { display: flex; align-items: center; gap: 8px; margin: 0; color: var(--acid-ink); font-family: var(--font-mono); font-size: 11px; letter-spacing: .06em; line-height: 1.45; text-transform: uppercase; }
.hero-location { margin: 13px 0 42px; color: var(--muted); font-family: var(--font-mono); font-size: 10px; letter-spacing: .065em; line-height: 1.45; }
.hero h1 { max-width: 930px; margin: 0; font-size: clamp(66px, 7.65vw, 114px); font-weight: 650; letter-spacing: -.065em; line-height: .92; text-wrap: balance; }
h1 em, h2 em { color: var(--acid-ink); font-family: var(--font-serif); font-weight: 400; letter-spacing: -.055em; }
.hero-intro { max-width: 620px; margin: 34px 0 0; color: #3f463f; font-size: clamp(18px, 1.35vw, 20px); letter-spacing: -.025em; line-height: 1.52; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 18px; align-items: center; margin-top: 33px; }
.button { display: inline-flex; min-height: 50px; align-items: center; justify-content: center; gap: 15px; padding: 0 20px; font-family: var(--font-mono); font-size: 11px; letter-spacing: .03em; text-transform: uppercase; transition: transform .2s ease, color .2s ease, background .2s ease; }
.button:hover { transform: translateY(-2px); }
.button-primary { color: var(--ink); background: var(--acid); }
.button-primary:hover { background: #d9ff5c; }
.button-quiet { min-height: auto; padding: 8px 0; border-bottom: 1px solid var(--ink); color: var(--ink); }
.button-quiet:hover { color: var(--acid-ink); }
.hero-tape { display: none; }
.hero-portrait-wrap { align-self: end; width: 100%; margin-bottom: 34px; }
.portrait-label-top { display: none; }
.portrait-frame { position: relative; aspect-ratio: 4 / 5; overflow: hidden; background: var(--ink-soft); }
.hero-portrait { display: block; width: 100%; height: 100%; object-fit: cover; object-position: 48% 50%; filter: saturate(.8) contrast(1.02); transform: scale(1.04); }
.portrait-scan, .portrait-orbit { display: none; }
.portrait-label { display: flex; justify-content: space-between; gap: 8px; margin-top: 10px; color: var(--muted); font-family: var(--font-mono); font-size: 9px; letter-spacing: .04em; }
.hero-note { position: absolute; right: 0; bottom: 18px; color: var(--muted); font-family: var(--font-mono); font-size: 10px; letter-spacing: .04em; }
.hero-note span { color: var(--acid-ink); }

.proof-strip { color: var(--paper); background: var(--ink); }
.proof-track { display: grid; grid-template-columns: repeat(4, 1fr); }
.proof-item { display: flex; min-height: 96px; align-items: center; gap: 12px; padding: 18px clamp(12px, 2vw, 28px); border-right: 1px solid var(--line-light); }
.proof-item:first-child { border-left: 1px solid var(--line-light); }
.proof-item strong { color: var(--acid); font-size: clamp(26px, 2.7vw, 42px); letter-spacing: -.08em; line-height: .92; }
.proof-item span { max-width: 125px; color: var(--paper-dim); font-family: var(--font-mono); font-size: 10px; letter-spacing: .025em; line-height: 1.4; text-transform: uppercase; }

.section { padding-top: clamp(92px, 9vw, 132px); }
.section h2, .contact h2 { margin: 0; font-size: clamp(52px, 6vw, 88px); font-weight: 630; letter-spacing: -.065em; line-height: .94; text-wrap: balance; }

.chat-section { padding-top: clamp(82px, 8vw, 116px); }
.chat-heading { display: grid; grid-template-columns: 1fr .68fr; gap: 50px; align-items: end; margin-bottom: 36px; }
.chat-heading h2 { margin-top: 14px; }
.chat-heading > p { max-width: 460px; margin: 0 0 3px; color: #4d544d; font-size: 16px; letter-spacing: -.015em; line-height: 1.58; }
.full-chat-link { display: inline-flex; min-height: 34px; align-items: center; gap: 12px; margin-top: 20px; padding: 0 12px; border: 1px solid var(--line); color: var(--ink); font-family: var(--font-mono); font-size: 10px; letter-spacing: .035em; text-transform: uppercase; transition: color .18s ease, border-color .18s ease, background .18s ease; }
.full-chat-link span { color: var(--acid-ink); }
.full-chat-link:hover { border-color: var(--acid-ink); color: var(--acid-ink); background: rgba(201,244,61,.12); }
.chat-shell { overflow: hidden; overflow-anchor: none; color: var(--paper); background: var(--ink-soft); }
.chat-rail { padding: 17px 24px; border-bottom: 1px solid var(--line-light); }
.chat-rail > div:first-child { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.chat-rail-label { margin-right: 9px; color: #a5aca4; font-family: var(--font-mono); font-size: 10px; letter-spacing: .06em; }
.prompt-chip { padding: 10px 13px; border: 1px solid var(--line-light); color: var(--paper-dim); background: transparent; font-size: 13px; line-height: 1.4; transition: color .2s ease, border-color .2s ease; }
.prompt-chip:hover { border-color: var(--acid); color: var(--acid); }
.chat-rail-bottom, .chat-panel-top { display: none; }
.chat-panel { display: flex; min-width: 0; flex-direction: column; }
.messages { height: 430px; min-height: 0; padding: 32px clamp(22px, 4vw, 56px); overflow: auto; overscroll-behavior: contain; overflow-anchor: none; scrollbar-color: var(--acid) transparent; scrollbar-width: thin; }
.message { width: fit-content; max-width: min(760px, 92%); margin-bottom: 27px; }
.message-label { display: block; margin-bottom: 10px; color: var(--acid); font-family: var(--font-mono); font-size: 10px; letter-spacing: .055em; }
.message-assistant .message-label { display: flex; align-items: center; gap: 8px; }
.message-assistant .message-label::before { content: ""; display: block; width: 28px; height: 28px; flex: 0 0 auto; border: 1px solid rgba(201,244,61,.66); border-radius: 50%; background: #101510 url("/assets/zhitao-chat-avatar-v2.png") center / cover no-repeat; box-shadow: 0 0 0 2px rgba(201,244,61,.08), 0 7px 20px rgba(0,0,0,.24); }
.message-copy { font-size: 16px; letter-spacing: -.012em; line-height: 1.65; }
.message-copy p, .message-copy h3, .message-copy h4, .message-copy ul, .message-copy ol, .message-copy blockquote { margin: 0; }
.message-copy p + p, .message-copy p + ul, .message-copy p + ol, .message-copy ul + p, .message-copy ol + p, .message-copy blockquote + p { margin-top: 12px; }
.message-copy h3, .message-copy h4 { margin-bottom: 9px; color: var(--paper); font-size: 18px; line-height: 1.35; }
.message-copy ul, .message-copy ol { padding-left: 21px; }
.message-copy li + li { margin-top: 4px; }
.message-copy blockquote { padding-left: 13px; border-left: 2px solid var(--acid); color: var(--paper-dim); }
.message-copy strong, .message-copy a { color: var(--acid); }
.message-copy a { text-decoration: underline; text-underline-offset: 3px; }
.message-copy code { padding: 2px 4px; color: var(--acid); background: rgba(201,244,61,.1); font-family: var(--font-mono); font-size: .86em; }
.message-image { width: min(300px, 100%); margin: 0 0 12px; overflow: hidden; border: 1px solid rgba(16,19,15,.22); background: #0d110d; }
.message-image img { display: block; width: 100%; max-height: 280px; object-fit: contain; }
.message-thinking { width: fit-content; max-width: 620px; margin: 0 0 15px; color: #a5aca4; font-family: var(--font-mono); font-size: 11px; line-height: 1.55; }
.message-thinking summary { display: flex; width: fit-content; align-items: center; gap: 8px; cursor: pointer; color: var(--paper-dim); list-style: none; }
.message-thinking summary::-webkit-details-marker { display: none; }
.message-thinking summary::before { content: "+"; display: inline-grid; width: 16px; height: 16px; place-items: center; border: 1px solid #5c655c; color: var(--acid); line-height: 1; }
.message-thinking[open] summary::before { content: "−"; }
.message-thinking p { max-width: 560px; margin: 9px 0 0 24px; color: #8f978e; }
.message-user { margin-left: auto; padding: 13px 15px; color: var(--ink); background: var(--acid); }
.message-user .message-label, .message-user .message-copy strong, .message-user .message-copy a { color: var(--acid-ink); }
.message-loading .message-copy { display: flex; align-items: center; gap: 10px; color: #a5aca4; font-family: var(--font-mono); font-size: 12px; }
.message-loading .message-copy::before { content: ""; width: 7px; height: 7px; flex: 0 0 auto; border-radius: 50%; background: var(--acid); box-shadow: 12px 0 0 rgba(201,244,61,.55), 24px 0 0 rgba(201,244,61,.2); animation: thinking-pulse 1.2s ease-in-out infinite; }
.message-loading .message-copy p { margin-left: 22px; }
.message-streaming .message-copy { min-height: 1.65em; white-space: pre-wrap; }
.message-streaming .message-copy::after { content: "▍"; display: inline-block; margin-left: 2px; color: var(--acid); font-size: .86em; animation: blink .85s step-end infinite; }
.chat-consent { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; padding: 13px 24px; border-top: 1px solid var(--line-light); color: #a5aca4; font-size: 12px; line-height: 1.5; }
.chat-consent label { display: flex; gap: 8px; max-width: 730px; }
.chat-consent input { width: 16px; height: 16px; flex: 0 0 auto; margin: 1px 0 0; accent-color: var(--acid); }
.chat-consent a { color: var(--paper-dim); text-decoration: underline; }
.wechat-browser-notice { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 14px 24px; border-top: 1px solid rgba(201,244,61,.35); border-bottom: 1px solid rgba(201,244,61,.18); color: var(--paper); background: rgba(201,244,61,.075); }
.wechat-browser-notice[data-state="blocked"] { border-color: rgba(255,183,77,.42); background: rgba(255,183,77,.085); }
.wechat-browser-notice > div:first-child { min-width: 0; }
.wechat-browser-notice strong, .wechat-browser-notice span { display: block; }
.wechat-browser-notice strong { color: var(--acid); font-size: 13px; font-weight: 560; }
.wechat-browser-notice[data-state="blocked"] strong { color: #ffc46b; }
.wechat-browser-notice span { margin-top: 3px; color: #b8beb6; font-size: 12px; line-height: 1.45; }
.wechat-browser-actions { display: flex; flex: 0 0 auto; gap: 8px; }
.wechat-browser-actions button { min-height: 34px; padding: 0 11px; border: 1px solid rgba(201,244,61,.42); color: var(--acid); background: transparent; font-family: var(--font-mono); font-size: 9px; letter-spacing: .03em; white-space: nowrap; text-transform: uppercase; }
.wechat-browser-actions button:hover { color: var(--ink); background: var(--acid); }
.wechat-browser-actions button[hidden] { display: none; }
.turnstile-widget { position: absolute; z-index: 20; right: 14px; bottom: calc(100% + 10px); display: flex; width: min(300px, calc(100% - 28px)); max-width: 300px; justify-content: center; overflow: hidden; border: 1px solid rgba(201,244,61,.38); opacity: 0; visibility: hidden; pointer-events: none; background: #101510; box-shadow: 0 18px 55px rgba(0,0,0,.38); transform: translateY(6px); transition: opacity .18s ease, transform .18s ease, visibility .18s ease; }
.turnstile-widget.is-visible { opacity: 1; visibility: visible; pointer-events: auto; transform: translateY(0); }
.wechat-browser-notice ~ .chat-form .turnstile-widget { position: relative; z-index: 1; right: auto; bottom: auto; display: none; width: 100%; max-width: none; flex: 1 0 100%; order: -1; margin: 0 auto 4px; }
.wechat-browser-notice ~ .chat-form .turnstile-widget.is-visible { display: flex; }
.chat-form { position: relative; display: flex; flex-wrap: wrap; gap: 10px 12px; align-items: flex-end; padding: 12px 14px 8px; border-top: 1px solid var(--line-light); }
.chat-image-preview { display: grid; width: 100%; grid-template-columns: 48px minmax(0, 1fr) auto; gap: 11px; align-items: center; padding: 8px; border: 1px solid rgba(201,244,61,.28); background: rgba(201,244,61,.045); }
.chat-image-preview[hidden] { display: none; }
.chat-image-preview img { display: block; width: 48px; height: 48px; object-fit: cover; background: #0c100c; }
.chat-image-preview div { min-width: 0; }
.chat-image-preview strong, .chat-image-preview span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.chat-image-preview strong { color: var(--paper); font-size: 13px; font-weight: 500; }
.chat-image-preview span { margin-top: 3px; color: #929a92; font-family: var(--font-mono); font-size: 9px; letter-spacing: .015em; }
.remove-chat-image { padding: 7px 4px; border: 0; color: var(--paper-dim); background: transparent; font-family: var(--font-mono); font-size: 9px; letter-spacing: .035em; text-decoration: underline; text-underline-offset: 3px; text-transform: uppercase; }
.remove-chat-image:hover { color: var(--acid); }
.remove-chat-image:disabled { cursor: wait; opacity: .45; }
.image-upload { position: relative; display: inline-grid; width: 44px; height: 44px; flex: 0 0 auto; place-items: center; border: 1px solid #4a524a; color: var(--paper-dim); cursor: pointer; transition: border-color .18s ease, color .18s ease, background .18s ease; }
.image-upload:hover { border-color: var(--acid); color: var(--acid); background: rgba(201,244,61,.06); }
.image-upload[aria-disabled="true"] { color: #697069; cursor: not-allowed; opacity: .55; }
.image-upload:focus-within { outline: 2px solid var(--acid); outline-offset: 3px; }
.image-upload svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.5; }
.image-upload input { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); clip-path: inset(50%); white-space: nowrap; }
.chat-form textarea { min-width: 0; min-height: 48px; max-height: 130px; flex: 1; padding: 11px 10px; resize: none; overflow-y: auto; border: 0; outline: 0; color: var(--paper); background: transparent; font-size: 16px; line-height: 1.5; }
.chat-form textarea::placeholder { color: #737b73; }
.chat-form textarea:disabled { cursor: not-allowed; }
.chat-form textarea:read-only { cursor: wait; }
#send-button { display: inline-flex; min-height: 44px; align-items: center; align-self: flex-end; gap: 10px; padding: 0 15px; border: 0; color: var(--ink); background: var(--acid); font-family: var(--font-mono); font-size: 10px; letter-spacing: .04em; text-transform: uppercase; }
#send-button:disabled { color: #6d736d; background: #303630; cursor: not-allowed; }
.chat-status { min-height: 31px; margin: 0; padding: 2px 24px 13px; color: #a5aca4; font-family: var(--font-mono); font-size: 10px; letter-spacing: .02em; }
.chat-status[data-type="success"] { color: var(--acid); }
.chat-status[data-type="error"] { color: #ff9a82; }

/* Dedicated AI counterpart */
.chat-page-body { background: var(--paper); }
.chat-page-header .desktop-nav { margin-left: auto; margin-right: auto; }
.chat-page-main { overflow: hidden; }
.standalone-chat { padding: clamp(52px, 6vw, 82px) 0 clamp(86px, 8vw, 118px); }
.standalone-chat-head { display: grid; grid-template-columns: 1fr .72fr; gap: clamp(48px, 8vw, 120px); align-items: end; margin-bottom: 39px; }
.standalone-chat-head h1 { max-width: 780px; margin: 15px 0 0; font-size: clamp(62px, 7.2vw, 108px); font-weight: 650; letter-spacing: -.07em; line-height: .9; text-wrap: balance; }
.standalone-chat-head > p { max-width: 560px; margin: 0 0 3px; color: #444b44; font-size: 17px; letter-spacing: -.02em; line-height: 1.6; }
.standalone-chat .chat-shell { display: grid; min-height: 660px; grid-template-columns: minmax(250px, 308px) minmax(0, 1fr); border: 1px solid rgba(16,19,15,.22); box-shadow: 0 34px 90px rgba(16,19,15,.1); }
.standalone-chat .chat-rail { display: flex; flex-direction: column; justify-content: space-between; padding: 27px 22px 24px; border-right: 1px solid var(--line-light); border-bottom: 0; }
.standalone-chat .chat-rail > div:first-child { display: flex; flex-direction: column; flex-wrap: nowrap; gap: 9px; align-items: stretch; }
.standalone-chat .chat-rail-label { margin: 0 0 5px; }
.standalone-chat .prompt-chip { width: 100%; min-height: 62px; padding: 13px 14px; text-align: left; }
.standalone-chat .chat-rail-bottom { display: grid; gap: 3px; color: #777f77; font-family: var(--font-mono); font-size: 9px; letter-spacing: .045em; line-height: 1.4; }
.standalone-chat .chat-rail-bottom strong { margin-bottom: 7px; color: var(--paper-dim); font-size: 10px; font-weight: 500; }
.standalone-chat .delete-chat { width: fit-content; margin-top: 11px; padding: 5px 0; border: 0; color: #929a92; background: transparent; font-family: var(--font-mono); font-size: 9px; text-decoration: underline; text-underline-offset: 3px; text-transform: uppercase; }
.standalone-chat .delete-chat:hover { color: var(--acid); }
.standalone-chat .chat-panel-top { display: flex; min-height: 48px; align-items: center; justify-content: space-between; gap: 18px; padding: 0 25px; border-bottom: 1px solid var(--line-light); color: #9aa29a; font-family: var(--font-mono); font-size: 9px; letter-spacing: .05em; }
.standalone-chat .chat-panel-top span:last-child { display: inline-flex; align-items: center; gap: 7px; }
.standalone-chat .messages { height: clamp(480px, 58svh, 680px); padding-top: 37px; }
.standalone-chat .message { max-width: min(820px, 92%); }
.standalone-chat .message-copy { font-size: 17px; }
.standalone-chat .chat-consent label { max-width: 820px; }

.chat-capabilities { padding: 0 0 clamp(100px, 10vw, 148px); }
.capability-heading { display: grid; grid-template-columns: 1.18fr .62fr; gap: clamp(50px, 8vw, 118px); align-items: end; margin-bottom: 47px; }
.capability-heading h2 { max-width: 820px; margin: 17px 0 0; font-size: clamp(51px, 5.8vw, 86px); font-weight: 630; letter-spacing: -.065em; line-height: .94; text-wrap: balance; }
.capability-heading > p { max-width: 420px; margin: 0 0 4px; color: #4d544d; font-size: 16px; line-height: 1.62; }
.capability-grid { display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.capability-card { display: flex; min-height: 330px; flex-direction: column; padding: 24px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); transition: background .22s ease, transform .22s ease; }
.capability-card:hover { z-index: 1; background: var(--paper-2); transform: translateY(-3px); }
.capability-card > span { color: var(--acid-ink); font-family: var(--font-mono); font-size: 10px; letter-spacing: .055em; text-transform: uppercase; }
.capability-card h3 { max-width: 220px; margin: 72px 0 14px; font-size: 28px; letter-spacing: -.055em; line-height: 1.02; }
.capability-card p { margin: 0; color: #4d544d; font-size: 14px; line-height: 1.6; }
.capability-card button { display: flex; width: 100%; align-items: center; justify-content: space-between; margin-top: auto; padding: 23px 0 0; border: 0; border-top: 1px solid var(--line); color: var(--ink); background: transparent; font-family: var(--font-mono); font-size: 10px; letter-spacing: .03em; text-align: left; text-transform: uppercase; }
.capability-card button i { color: var(--acid-ink); font-style: normal; font-size: 16px; }
.capability-card button:hover { color: var(--acid-ink); }

.chat-principles { padding: clamp(88px, 9vw, 132px) 0; color: var(--paper); background: var(--ink-soft); }
.chat-principles-inner { display: grid; grid-template-columns: .72fr 1.28fr; gap: clamp(65px, 9vw, 135px); }
.principles-intro .eyebrow { color: var(--acid); }
.principles-intro h2 { margin: 18px 0 0; font-size: clamp(48px, 5.5vw, 82px); font-weight: 630; letter-spacing: -.065em; line-height: .95; }
.principles-intro h2 em { color: var(--acid); }
.principles-intro > p:last-child { max-width: 470px; margin: 28px 0 0; color: var(--paper-dim); font-size: 16px; line-height: 1.66; }
.principle-grid { display: grid; grid-template-columns: repeat(2, 1fr); border-top: 1px solid var(--line-light); border-left: 1px solid var(--line-light); }
.principle-grid article { min-height: 235px; padding: 23px 25px; border-right: 1px solid var(--line-light); border-bottom: 1px solid var(--line-light); }
.principle-grid span { color: var(--acid); font-family: var(--font-mono); font-size: 10px; }
.principle-grid h3 { margin: 59px 0 9px; font-size: 25px; letter-spacing: -.045em; }
.principle-grid p { margin: 0; color: #aeb3ab; font-size: 14px; line-height: 1.6; }

.chat-skill { padding: clamp(92px, 10vw, 145px) 0 0; }
.chat-skill-card { display: grid; grid-template-columns: 1fr .9fr; gap: clamp(50px, 9vw, 130px); padding: clamp(38px, 5vw, 70px); color: var(--paper); background: var(--ink-soft); }
.chat-skill-card .eyebrow { color: var(--acid); }
.chat-skill-card h2 { margin: 17px 0 0; font-size: clamp(47px, 5vw, 76px); font-weight: 630; letter-spacing: -.065em; line-height: .96; }
.chat-skill-card h2 em { color: var(--acid); }
.chat-skill-card > div:first-child > p:last-child { max-width: 590px; margin: 24px 0 0; color: var(--paper-dim); font-size: 16px; line-height: 1.65; }
.chat-skill-card > div:last-child { align-self: end; }
.chat-skill-card .install-box { margin-top: 0; }
.chat-skill-card .text-link { display: inline-block; margin-top: 19px; }
.chat-contact { padding: clamp(100px, 11vw, 160px) 0 67px; }
.chat-contact h2 { max-width: 960px; margin: 22px 0 0; font-size: clamp(62px, 8.5vw, 122px); font-weight: 630; letter-spacing: -.065em; line-height: .92; text-wrap: balance; }

.section-heading { display: grid; grid-template-columns: .56fr 1.08fr .64fr; gap: 40px; align-items: end; margin-bottom: 46px; }
.section-heading h2 { max-width: 720px; }
.section-heading > p:last-child { max-width: 310px; margin: 0 0 3px; color: #4d544d; font-size: 16px; line-height: 1.58; }
.eyebrow span { color: var(--muted); }
.section-index { margin: 13px 0 0; color: var(--muted); font-family: var(--font-mono); font-size: 10px; letter-spacing: .05em; }
.work-grid { border-top: 1px solid var(--line); }
.case-card { position: relative; display: grid; min-height: 245px; grid-template-columns: 150px minmax(0, 1fr) 280px; color: var(--ink); background: transparent; border-bottom: 1px solid var(--line); transition: background .25s ease; }
.case-card:hover { background: rgba(16,19,15,.035); }
.case-topline { display: block; padding: 31px 22px 31px 0; color: var(--muted); font-family: var(--font-mono); font-size: 10px; letter-spacing: .06em; }
.case-topline span { display: block; }
.case-topline span + span { margin-top: 11px; color: var(--acid-ink); }
.case-body { width: auto; padding: 31px 42px; border-left: 1px solid var(--line); }
.case-kicker { margin: 0 0 14px; color: var(--muted); font-family: var(--font-mono); font-size: 11px; letter-spacing: .06em; text-transform: uppercase; }
.case-body h3 { max-width: 720px; margin: 0; font-size: clamp(31px, 3.2vw, 48px); font-weight: 620; letter-spacing: -.065em; line-height: .96; }
.case-body > p:last-child { max-width: 650px; margin: 18px 0 0; color: #4b524b; font-size: 15px; letter-spacing: -.012em; line-height: 1.6; }
.case-footer { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; padding: 31px 0 31px 32px; border-left: 1px solid var(--line); color: var(--muted); font-family: var(--font-mono); font-size: 10px; letter-spacing: .05em; }
.case-footer span:last-child { color: var(--acid-ink); font-size: 18px; }
.case-shape { display: none; }
.disclaimer { margin: 17px 0 0; color: var(--muted); font-family: var(--font-mono); font-size: 10px; letter-spacing: .03em; line-height: 1.5; }

.system { margin-top: clamp(100px, 10vw, 145px); padding: clamp(84px, 9vw, 128px) 0; color: var(--ink); background: var(--paper-2); }
.system-inner { display: grid; grid-template-columns: .75fr 1.25fr; gap: clamp(60px, 8vw, 120px); }
.system-aside { position: sticky; top: 36px; align-self: start; }
.system-aside h2 { margin-top: 17px; }
.system-aside > p:last-child { max-width: 380px; margin: 27px 0 0; color: #4c534c; font-size: 16px; line-height: 1.62; }
.system-list { margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--line); }
.system-list li { display: grid; grid-template-columns: 50px 1fr 22px; gap: 16px; padding: 25px 0 28px; border-bottom: 1px solid var(--line); }
.system-list li > span { padding-top: 5px; color: var(--acid-ink); font-family: var(--font-mono); font-size: 11px; }
.system-list h3 { margin: 0; font-size: clamp(24px, 2.5vw, 35px); letter-spacing: -.06em; }
.system-list p { max-width: 540px; margin: 9px 0 0; color: #4c534c; font-size: 15px; line-height: 1.6; }
.system-list i { align-self: center; font-style: normal; }

.experience-header { display: flex; align-items: end; justify-content: space-between; gap: 40px; margin-bottom: 50px; }
.experience-header h2 { max-width: 760px; }
.experience-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-top: 1px solid var(--line); }
.experience-card { min-height: 310px; padding: 23px 26px 26px; border-right: 1px solid var(--line); }
.experience-card:first-child { border-left: 1px solid var(--line); }
.experience-year { color: var(--muted); font-family: var(--font-mono); font-size: 11px; }
.experience-card h3 { margin: 83px 0 4px; font-size: 26px; letter-spacing: -.065em; }
.experience-card p { margin: 0; color: #4d544d; font-size: 14px; }
.experience-card small { color: var(--muted); }
.experience-card ul { display: flex; flex-wrap: wrap; gap: 8px 14px; margin: 23px 0 0; padding: 0; list-style: none; }
.experience-card li { color: var(--muted); font-family: var(--font-mono); font-size: 10px; letter-spacing: .025em; text-transform: uppercase; }

.skill-window { overflow: hidden; color: var(--paper); background: var(--ink-soft); }
.window-bar { display: flex; height: 40px; align-items: center; gap: 6px; padding: 0 16px; border-bottom: 1px solid var(--line-light); }
.window-bar span { width: 7px; height: 7px; border: 1px solid #7f887f; border-radius: 50%; }
.window-bar span:first-child { border-color: var(--acid); }
.window-bar p { margin: 0 auto; color: #a5aca4; font-family: var(--font-mono); font-size: 10px; }
.skill-content { display: grid; min-height: 440px; grid-template-columns: .46fr 1.54fr; }
.skill-number { display: flex; align-items: flex-end; padding: 38px 32px; border-right: 1px solid var(--line-light); color: var(--acid); font-size: clamp(78px, 10vw, 142px); font-weight: 700; letter-spacing: -.12em; line-height: .8; }
.skill-number span { color: var(--paper); opacity: .45; }
.skill-copy { max-width: 760px; padding: 61px 8% 44px; }
.skill-copy .eyebrow { color: var(--acid); }
.skill-copy h2 { margin-top: 18px; }
.skill-copy h2 em { color: var(--acid); }
.skill-copy > p:not(.eyebrow) { max-width: 600px; margin: 25px 0 0; color: var(--paper-dim); font-size: 16px; line-height: 1.65; }
.install-box { display: flex; gap: 14px; align-items: stretch; margin-top: 29px; padding: 10px 10px 10px 14px; border: 1px solid var(--line-light); }
.install-box code { flex: 1; color: var(--paper-dim); font-family: var(--font-mono); font-size: 11px; line-height: 1.6; overflow-wrap: anywhere; }
.copy-button { min-width: 64px; border: 1px solid var(--acid); color: var(--acid); background: transparent; font-family: var(--font-mono); font-size: 10px; text-transform: uppercase; }
.copy-button:hover { color: var(--ink); background: var(--acid); }
.skill-actions { display: flex; flex-wrap: wrap; gap: 27px; margin-top: 20px; }
.text-link { color: var(--paper); font-family: var(--font-mono); font-size: 11px; text-transform: uppercase; }
.text-link span { color: var(--acid); }

.contact { padding-top: clamp(100px, 11vw, 155px); padding-bottom: 64px; }
.contact-rule { height: 1px; margin-bottom: 42px; background: var(--line); }
.contact h2 { max-width: 800px; margin-top: 23px; font-size: clamp(66px, 9vw, 128px); }
.contact-actions { display: flex; flex-wrap: wrap; gap: 28px; margin-top: 37px; }
.contact-actions a { padding-bottom: 5px; border-bottom: 1px solid var(--ink); font-family: var(--font-mono); font-size: 12px; }
.contact-actions span { color: var(--acid-ink); }
.site-footer { display: flex; gap: 20px; justify-content: space-between; padding: 20px 0 26px; border-top: 1px solid var(--line); color: var(--muted); font-family: var(--font-mono); font-size: 10px; letter-spacing: .05em; }
.site-footer a { text-decoration: underline; }

.privacy h1 em { color: var(--acid-ink) !important; }
.privacy p, .privacy li { color: #4d544d !important; }
.privacy a { color: var(--acid-ink) !important; }
.privacy .back { color: var(--ink) !important; }

.reveal { opacity: 1; transform: translateY(0); }
.js .reveal { opacity: 0; transform: translateY(14px); transition: opacity .65s ease, transform .65s cubic-bezier(.2,.7,.1,1); }
.js .reveal.in-view { opacity: 1; transform: translateY(0); }
@keyframes blink { 0%,100% { opacity: 1; } 50% { opacity: .35; } }
@keyframes thinking-pulse { 0%,100% { opacity: .35; transform: translateX(0); } 50% { opacity: 1; transform: translateX(3px); } }

@media (max-width: 980px) {
  :root { --shell: min(100% - 48px, 1380px); }
  .hero { grid-template-columns: minmax(0, 1fr) 210px; gap: 45px; }
  .hero h1 { font-size: clamp(65px, 9vw, 100px); }
  .case-card { grid-template-columns: 120px minmax(0, 1fr) 220px; }
  .case-body { padding-inline: 30px; }
  .case-footer { padding-left: 24px; }
  .standalone-chat .chat-shell { grid-template-columns: 250px minmax(0, 1fr); }
  .capability-grid { grid-template-columns: repeat(2, 1fr); }
  .capability-card { min-height: 290px; }
  .chat-principles-inner { grid-template-columns: 1fr; }
  .principles-intro { max-width: 720px; }
  .experience-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .experience-card:nth-child(2n + 1) { border-left: 1px solid var(--line); }
  .experience-card:nth-child(n + 3) { border-top: 1px solid var(--line); }
}

@media (max-width: 760px) {
  :root { --shell: min(100% - 38px, 1380px); }
  .site-header { height: 70px; }
  .desktop-nav { display: none; }
  .hero { display: grid; min-height: 0; grid-template-columns: minmax(0, 1fr) 120px; gap: 28px 20px; align-items: end; padding: 58px 0 48px; }
  .hero-copy { grid-column: 1 / -1; }
  .hero h1 { max-width: 680px; font-size: clamp(60px, 12.5vw, 88px); }
  .hero-portrait-wrap { grid-column: 2; grid-row: 2; width: 120px; margin: 0; }
  .portrait-label { display: none; }
  .hero-note { display: none; }
  .hero-intro { grid-column: 1; }
  .proof-track { grid-template-columns: repeat(2, 1fr); }
  .proof-item:nth-child(2n + 1) { border-left: 1px solid var(--line-light); }
  .proof-item:nth-child(n + 3) { border-top: 1px solid var(--line-light); }
  .chat-heading, .section-heading { grid-template-columns: 1fr; gap: 21px; }
  .chat-heading > p, .section-heading > p:last-child { max-width: 540px; }
  .chat-rail > div:first-child { align-items: stretch; }
  .chat-rail-label { width: 100%; margin-bottom: 2px; }
  .prompt-chip { flex: 1; min-width: 160px; text-align: left; }
  .work-grid { border-top: 1px solid var(--line); }
  .case-card { display: block; min-height: 0; padding: 27px 0; }
  .case-topline { display: flex; justify-content: space-between; padding: 0 0 23px; }
  .case-topline span + span { margin: 0; }
  .case-body { padding: 0; border: 0; }
  .case-footer { margin-top: 26px; padding: 0; border: 0; }
  .system { margin-top: 95px; }
  .system-inner { grid-template-columns: 1fr; gap: 46px; }
  .system-aside { position: static; }
  .experience-header { display: grid; gap: 23px; }
  .experience-grid { grid-template-columns: 1fr; }
  .experience-card, .experience-card:first-child { min-height: 210px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); border-left: 1px solid var(--line); }
  .experience-card h3 { margin-top: 44px; }
  .skill-content { grid-template-columns: 1fr; }
  .skill-number { display: none; }
  .skill-copy { padding: 50px 8% 42px; }
  .standalone-chat-head, .capability-heading { grid-template-columns: 1fr; gap: 23px; }
  .standalone-chat-head > p, .capability-heading > p { max-width: 650px; }
  .standalone-chat .chat-shell { display: block; min-height: 0; }
  .standalone-chat .chat-rail { display: block; padding: 17px 20px; border-right: 0; border-bottom: 1px solid var(--line-light); }
  .standalone-chat .chat-rail > div:first-child { flex-flow: row wrap; }
  .standalone-chat .chat-rail-label { width: 100%; }
  .standalone-chat .prompt-chip { width: auto; min-height: 52px; flex: 1 1 210px; }
  .standalone-chat .chat-rail-bottom { display: none; }
  .standalone-chat .messages { height: clamp(430px, 55svh, 600px); }
  .chat-skill-card { grid-template-columns: 1fr; }
}

@media (max-width: 520px) {
  :root { --shell: calc(100vw - 32px); }
  .brand > span:last-child { display: none; }
  .nav-chat { font-size: 10px; }
  .header-actions { gap: 13px; }
  .language-switcher { gap: 5px; font-size: 9px; }
  .hero { display: block; padding-top: 44px; }
  .hero-location { margin-bottom: 30px; }
  .hero h1 { font-size: clamp(49px, 13.7vw, 60px); letter-spacing: -.045em; line-height: .97; }
  .hero-intro { margin-top: 27px; font-size: 17px; line-height: 1.55; }
  .hero-actions { display: flex; align-items: center; gap: 18px; margin-top: 28px; }
  .button-primary { flex: 1; }
  .button-quiet { flex: 0 0 auto; font-size: 10px; }
  .hero-portrait-wrap { width: 104px; margin: 34px 0 0 auto; }
  .portrait-frame { aspect-ratio: 1; border-radius: 50%; }
  .hero-portrait { object-position: 50% 34%; }
  .proof-item { min-height: 86px; flex-direction: column; align-items: flex-start; justify-content: center; gap: 5px; padding: 12px; }
  .proof-item strong { font-size: 31px; }
  .section { padding-top: 78px; }
  .section h2 { font-size: clamp(43px, 13vw, 60px); }
  .chat-section { padding-top: 72px; }
  .chat-heading > p { font-size: 16px; }
  .chat-rail { padding: 14px 16px; }
  .prompt-chip { min-width: 145px; padding: 10px; font-size: 13px; }
  .messages { height: clamp(250px, 39svh, 350px); padding: 25px 16px; }
  .message { max-width: 95%; }
  .message-copy { font-size: 16px; }
  .chat-consent { padding: 13px 16px; font-size: 12px; }
  .wechat-browser-notice { align-items: flex-start; flex-direction: column; padding: 14px 16px; }
  .wechat-browser-actions { width: 100%; }
  .wechat-browser-actions button { flex: 1; }
  .chat-form { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 8px; align-items: end; padding: 12px 12px 7px; }
  .chat-image-preview { grid-column: 1 / -1; }
  .image-upload { width: 48px; height: 48px; }
  .turnstile-widget { right: 12px; bottom: calc(100% + 8px); width: min(300px, calc(100% - 24px)); }
  .chat-form textarea { width: 100%; min-height: 72px; padding: 8px 4px; font-size: 16px; line-height: 1.5; }
  #send-button { min-width: 74px; min-height: 48px; padding-inline: 12px; }
  .chat-status { min-height: 27px; padding: 1px 12px 12px; font-size: 10px; line-height: 1.4; }
  .full-chat-link { min-height: 38px; margin-top: 17px; font-size: 10px; }
  .chat-page-header .nav-chat { font-size: 9px; }
  .standalone-chat { padding: 45px 0 82px; }
  .standalone-chat-head { margin-bottom: 27px; }
  .standalone-chat-head h1 { font-size: clamp(52px, 15.4vw, 68px); letter-spacing: -.06em; line-height: .94; }
  .standalone-chat-head > p { font-size: 16px; line-height: 1.62; }
  .standalone-chat .chat-rail { padding: 14px 16px; }
  .standalone-chat .prompt-chip { min-width: 135px; min-height: 0; padding: 11px; font-size: 13px; }
  .standalone-chat .chat-panel-top { min-height: 42px; padding: 0 16px; }
  .standalone-chat .chat-panel-top span:last-child { display: none; }
  .standalone-chat .messages { height: clamp(340px, 48svh, 470px); padding-top: 25px; }
  .standalone-chat .message-copy { font-size: 16px; }
  .chat-capabilities { padding-bottom: 90px; }
  .capability-heading { margin-bottom: 31px; }
  .capability-heading h2 { font-size: clamp(43px, 13vw, 58px); }
  .capability-grid { grid-template-columns: 1fr; }
  .capability-card { min-height: 255px; padding: 21px; }
  .capability-card h3 { margin-top: 43px; font-size: 28px; }
  .chat-principles { padding: 78px 0; }
  .chat-principles-inner { gap: 45px; }
  .principles-intro h2 { font-size: clamp(43px, 13vw, 58px); }
  .principles-intro > p:last-child { font-size: 15px; }
  .principle-grid { grid-template-columns: 1fr; }
  .principle-grid article { min-height: 190px; padding: 21px; }
  .principle-grid h3 { margin-top: 40px; }
  .chat-skill { padding-top: 82px; }
  .chat-skill-card { gap: 37px; padding: 32px 20px; }
  .chat-skill-card h2 { font-size: clamp(42px, 12.4vw, 55px); }
  .chat-skill-card > div:first-child > p:last-child { font-size: 15px; }
  .chat-contact { padding-top: 88px; }
  .chat-contact h2 { font-size: clamp(55px, 17vw, 78px); }
  .case-card { padding: 25px 0; }
  .case-body h3 { font-size: 34px; }
  .case-body > p:last-child { font-size: 15px; }
  .case-footer { font-size: 10px; }
  .system { margin-top: 78px; padding: 72px 0; }
  .system-list li { grid-template-columns: 34px 1fr 15px; gap: 9px; }
  .system-list h3 { font-size: 25px; }
  .system-list p { font-size: 15px; }
  .skill-copy { padding: 42px 20px 33px; }
  .install-box { gap: 8px; }
  .install-box code { font-size: 10px; }
  .copy-button { min-width: 54px; }
  .contact { padding-top: 86px; }
  .contact h2 { font-size: clamp(58px, 18vw, 86px); }
  .contact-actions { display: grid; gap: 14px; }
  .site-footer { flex-wrap: wrap; font-size: 10px; }
  .site-footer span:nth-child(2) { width: 100%; order: 3; }
}

@media (max-width: 360px) {
  #send-button { min-width: 52px; }
  #send-button span { display: none; }
  #send-button b { font-size: 16px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .reveal { opacity: 1; transform: none; transition: none; }
  .status-dot { animation: none; }
}

/* Dedicated chat application v2 */
.chat-page-body {
  height: 100svh;
  height: 100dvh;
  overflow: hidden;
  color: #f1f0e9;
  background: #0e110e;
}
.chat-page-body::selection { color: #10130f; background: var(--acid); }
.chat-page-body :focus-visible { outline-color: var(--acid); }
.chat-app-layout { position: relative; z-index: 1; display: grid; height: 100%; grid-template-columns: 72px minmax(0, 1fr); }
.chat-app-rail { position: relative; z-index: 40; display: flex; min-height: 0; flex-direction: column; align-items: center; padding: 16px 10px 13px; border-right: 1px solid rgba(241,240,233,.1); background: #0a0c0a; }
.chat-rail-logo { display: grid; width: 38px; height: 38px; place-items: center; overflow: hidden; background: var(--acid); }
.chat-rail-logo img { width: 100%; height: 100%; object-fit: cover; transform: scale(1.12); }
.chat-rail-tools { display: flex; flex: 1; flex-direction: column; gap: 10px; align-items: center; margin-top: 42px; }
.chat-rail-action { display: flex; width: 48px; min-height: 48px; flex-direction: column; align-items: center; justify-content: center; gap: 3px; padding: 5px 2px; border: 0; border-radius: 12px; color: #9ba19a; background: transparent; font-family: var(--font-mono); font-size: 8px; letter-spacing: .02em; text-align: center; transition: color .18s ease, background .18s ease; }
.chat-rail-action svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; stroke-width: 1.5; }
.chat-rail-action:hover, .chat-about-menu[open] > summary { color: var(--paper); background: #20241f; }
.chat-about-menu { position: relative; }
.chat-about-menu > summary { cursor: pointer; list-style: none; }
.chat-about-menu > summary::-webkit-details-marker { display: none; }
.chat-about-panel { position: absolute; z-index: 60; top: -58px; left: 62px; width: min(390px, calc(100vw - 108px)); max-height: calc(100dvh - 32px); overflow-y: auto; padding: 25px; border: 1px solid rgba(241,240,233,.14); border-radius: 18px; color: var(--paper); background: #191d18; box-shadow: 0 28px 80px rgba(0,0,0,.48); }
.chat-about-kicker { margin: 0 0 10px; color: var(--acid); font-family: var(--font-mono); font-size: 9px; letter-spacing: .055em; text-transform: uppercase; }
.chat-about-panel h2 { margin: 0; font-size: 27px; font-weight: 610; letter-spacing: -.05em; line-height: 1.05; }
.chat-about-panel > p:not(.chat-about-kicker) { margin: 14px 0 0; color: #b6bbb4; font-size: 14px; line-height: 1.58; }
.chat-about-panel ul { margin: 14px 0 0; padding: 0; list-style: none; }
.chat-about-panel li { padding: 8px 0; border-top: 1px solid rgba(241,240,233,.1); color: #d2d5cf; font-size: 13px; }
.chat-about-proof { display: flex; flex-wrap: wrap; gap: 7px; margin: 17px 0 23px; }
.chat-about-proof span { padding: 7px 9px; border: 1px solid rgba(201,244,61,.28); border-radius: 999px; color: var(--acid); font-family: var(--font-mono); font-size: 9px; }
.chat-about-install { display: flex; align-items: stretch; gap: 7px; }
.chat-about-install code { min-width: 0; flex: 1; padding: 10px; overflow: hidden; color: #aeb4ac; background: #10130f; font-family: var(--font-mono); font-size: 9px; line-height: 1.45; text-overflow: ellipsis; white-space: nowrap; }
.chat-about-install button { flex: 0 0 auto; padding: 0 12px; border: 1px solid var(--acid); border-radius: 8px; color: var(--acid); background: transparent; font-family: var(--font-mono); font-size: 9px; }
.chat-about-install button:hover { color: var(--ink); background: var(--acid); }
.chat-about-links { display: flex; flex-wrap: wrap; gap: 18px; margin-top: 17px; }
.chat-about-links a { color: var(--paper); font-family: var(--font-mono); font-size: 9px; text-decoration: underline; text-underline-offset: 3px; }
.chat-rail-language { display: grid; gap: 4px; font-family: var(--font-mono); font-size: 9px; text-align: center; }
.chat-rail-language a, .chat-rail-language span { display: grid; width: 28px; height: 24px; place-items: center; border-radius: 7px; color: #737a72; }
.chat-rail-language span[aria-current="true"] { color: var(--ink); background: var(--acid); }
.chat-rail-language a:hover { color: var(--paper); background: #20241f; }

.chat-workspace { display: grid; min-width: 0; min-height: 0; grid-template-rows: 64px minmax(0, 1fr); background: radial-gradient(circle at 50% 28%, rgba(201,244,61,.035), transparent 35%), #0e110e; }
.chat-app-topbar { display: flex; min-width: 0; align-items: center; justify-content: space-between; gap: 22px; padding: 0 24px; border-bottom: 1px solid rgba(241,240,233,.09); }
.chat-counterpart-id { display: flex; min-width: 0; align-items: center; gap: 10px; }
.chat-counterpart-id img { width: 32px; height: 32px; flex: 0 0 auto; border: 1px solid rgba(201,244,61,.48); border-radius: 50%; object-fit: cover; }
.chat-counterpart-id div { display: grid; min-width: 0; gap: 1px; }
.chat-counterpart-id strong { font-size: 14px; font-weight: 600; letter-spacing: -.02em; }
.chat-counterpart-id span { color: #828981; font-family: var(--font-mono); font-size: 8px; letter-spacing: .055em; text-transform: uppercase; }
.chat-topbar-state { display: flex; align-items: center; gap: 7px; color: #838a82; font-family: var(--font-mono); font-size: 9px; letter-spacing: .025em; text-transform: uppercase; }
.chat-topbar-state i { width: 6px; height: 6px; border-radius: 50%; background: var(--acid); box-shadow: 0 0 9px rgba(201,244,61,.65); }
.chat-topbar-state b { color: #4c534c; font-weight: 400; }

.chat-thread { min-width: 0; min-height: 0; overflow: hidden; }
.chat-thread-inner { display: flex; width: min(850px, calc(100% - 40px)); height: 100%; flex-direction: column; justify-content: center; margin: 0 auto; padding: 28px 0; }
.chat-empty-state { display: grid; justify-items: center; margin: 0 auto 28px; text-align: center; }
.chat-empty-state > img { width: 54px; height: 54px; border: 1px solid rgba(201,244,61,.55); border-radius: 50%; object-fit: cover; box-shadow: 0 0 0 5px rgba(201,244,61,.045), 0 16px 42px rgba(0,0,0,.34); }
.chat-empty-state > p { margin: 15px 0 9px; color: var(--acid); font-family: var(--font-mono); font-size: 9px; letter-spacing: .07em; text-transform: uppercase; }
.chat-empty-state h1 { margin: 0; font-size: clamp(35px, 4vw, 54px); font-weight: 580; letter-spacing: -.055em; line-height: 1.02; text-wrap: balance; }
.chat-empty-state > span { max-width: 640px; margin-top: 14px; color: #aeb3ac; font-size: 15px; letter-spacing: -.01em; line-height: 1.55; }
.chat-page-body .messages { display: none; width: 100%; height: auto; min-height: 0; padding: 46px 4px 34px; overflow-y: auto; overscroll-behavior: contain; }
.chat-page-body.chat-has-conversation .chat-thread-inner { display: grid; grid-template-rows: minmax(0, 1fr) auto; justify-content: stretch; padding: 0; }
.chat-page-body.chat-has-conversation .chat-empty-state { display: none; }
.chat-page-body.chat-has-conversation .messages { display: block; grid-row: 1; }
.chat-page-body .message { max-width: min(760px, 88%); margin-bottom: 32px; }
.chat-page-body .message-assistant { width: 100%; max-width: 100%; }
.chat-page-body .message-label { margin-bottom: 12px; font-size: 9px; }
.chat-page-body .message-assistant .message-label::before { width: 30px; height: 30px; }
.chat-page-body .message-copy { color: #e7e8e2; font-size: 17px; line-height: 1.72; }
.chat-page-body .message-user { max-width: min(650px, 82%); padding: 12px 16px; border-radius: 18px 18px 4px 18px; color: var(--paper); background: #292e28; }
.chat-page-body .message-user .message-label { color: #a5aca4; }
.chat-page-body .message-user .message-copy strong, .chat-page-body .message-user .message-copy a { color: var(--acid); }

.chat-composer-stack { position: relative; width: 100%; }
.chat-page-body.chat-has-conversation .chat-composer-stack { grid-row: 2; padding-bottom: max(18px, env(safe-area-inset-bottom)); background: linear-gradient(180deg, rgba(14,17,14,0), #0e110e 20%); }
.chat-page-body .chat-consent { display: flex; align-items: center; gap: 14px; padding: 0 12px 9px; border: 0; color: #7e857d; font-size: 10px; line-height: 1.35; }
.chat-page-body .chat-consent label { max-width: none; align-items: center; }
.chat-page-body .chat-consent input { width: 15px; height: 15px; margin: 0; }
.chat-page-body .chat-consent a { margin-left: auto; color: #9ba19a; }
.chat-page-body .chat-form { display: flex; flex-wrap: wrap; gap: 8px; align-items: flex-end; padding: 9px; border: 1px solid rgba(241,240,233,.12); border-radius: 25px; background: #222621; box-shadow: 0 18px 55px rgba(0,0,0,.27); transition: border-color .18s ease, box-shadow .18s ease; }
.chat-page-body .chat-form:focus-within { border-color: rgba(201,244,61,.42); box-shadow: 0 18px 60px rgba(0,0,0,.33), 0 0 0 1px rgba(201,244,61,.06); }
.chat-page-body .chat-image-preview { border-radius: 15px; }
.chat-page-body .image-upload { width: 44px; height: 44px; border: 0; border-radius: 50%; color: #aab0a8; }
.chat-page-body .image-upload:hover { color: var(--acid); background: #30362f; }
.chat-page-body .chat-form textarea { min-height: 44px; max-height: 135px; padding: 10px 5px; color: var(--paper); font-size: 16px; line-height: 1.5; }
.chat-page-body .chat-form textarea::placeholder { color: #838a82; }
.chat-page-body #send-button { display: grid; width: 44px; min-width: 44px; min-height: 44px; flex: 0 0 auto; place-items: center; padding: 0; border-radius: 50%; }
.chat-page-body #send-button span { display: none; }
.chat-page-body #send-button b { font-size: 16px; }
.chat-page-body #send-button:disabled { color: #777e76; background: #343934; }
.chat-page-body .turnstile-widget { right: 8px; bottom: calc(100% + 12px); border-radius: 13px; }
.chat-page-body .chat-status { min-height: 25px; padding: 7px 12px 2px; font-size: 9px; }
.chat-starters { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin-top: 14px; }
.chat-starters button { position: relative; display: grid; min-height: 78px; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 12px; align-content: center; padding: 12px 15px; border: 1px solid rgba(241,240,233,.1); border-radius: 14px; color: var(--paper); background: #151815; text-align: left; transition: border-color .18s ease, background .18s ease, transform .18s ease; }
.chat-starters button:hover { border-color: rgba(201,244,61,.42); background: #1b1f1a; transform: translateY(-1px); }
.chat-starters strong { font-size: 13px; font-weight: 560; letter-spacing: -.015em; }
.chat-starters span { grid-column: 1; color: #7f867e; font-size: 11px; line-height: 1.35; }
.chat-starters i { grid-column: 2; grid-row: 1 / 3; align-self: center; color: var(--acid); font-style: normal; font-size: 14px; }
.chat-grounding-note { margin: 13px 10px 0; color: #5f665f; font-family: var(--font-mono); font-size: 8px; letter-spacing: .02em; line-height: 1.45; text-align: center; }
.chat-page-body.chat-has-conversation .chat-starters,
.chat-page-body.chat-has-conversation .chat-grounding-note { display: none; }

html[lang^="zh"] .chat-empty-state > span,
html[lang^="zh"] .chat-page-body .message-copy { line-height: 1.78; }
html[lang^="zh"] .chat-starters button { letter-spacing: 0; }

@media (max-height: 760px) and (min-width: 701px) {
  .chat-thread-inner { padding-block: 18px; }
  .chat-empty-state { margin-bottom: 18px; }
  .chat-empty-state > img { width: 44px; height: 44px; }
  .chat-empty-state > p { margin-top: 11px; }
  .chat-empty-state h1 { font-size: 38px; }
  .chat-empty-state > span { margin-top: 10px; font-size: 14px; }
  .chat-starters button { min-height: 66px; }
  .chat-grounding-note { display: none; }
}

@media (max-width: 700px) {
  .chat-app-layout { grid-template-columns: minmax(0, 1fr); grid-template-rows: 58px minmax(0, 1fr); }
  .chat-app-rail { display: flex; height: 58px; min-height: 58px; flex-direction: row; padding: 8px 12px; border-right: 0; border-bottom: 1px solid rgba(241,240,233,.1); }
  .chat-rail-logo { width: 34px; height: 34px; }
  .chat-rail-tools { flex: 1; flex-direction: row; justify-content: flex-end; gap: 3px; margin: 0 8px 0 0; }
  .chat-rail-action { width: 40px; min-height: 40px; border-radius: 10px; }
  .chat-rail-action span { display: none; }
  .chat-rail-action svg { width: 19px; height: 19px; }
  .chat-rail-language { display: flex; gap: 2px; }
  .chat-rail-language a, .chat-rail-language span { width: 27px; height: 34px; }
  .chat-about-panel { position: fixed; top: 66px; right: 12px; left: 12px; width: auto; max-height: calc(100dvh - 78px); }
  .chat-workspace { grid-template-rows: 52px minmax(0, 1fr); }
  .chat-app-topbar { padding: 0 14px; }
  .chat-counterpart-id img { width: 29px; height: 29px; }
  .chat-topbar-state { font-size: 8px; }
  .chat-topbar-state b, .chat-topbar-state span:last-child { display: none; }
  .chat-thread-inner { width: min(100% - 24px, 850px); padding: 20px 0 max(14px, env(safe-area-inset-bottom)); }
  .chat-empty-state { margin-bottom: 20px; }
  .chat-empty-state > img { width: 46px; height: 46px; }
  .chat-empty-state > p { margin: 12px 0 7px; font-size: 8px; }
  .chat-empty-state h1 { font-size: clamp(30px, 9vw, 40px); line-height: 1.06; }
  .chat-empty-state > span { max-width: 520px; margin-top: 11px; font-size: 14px; line-height: 1.52; }
  .chat-page-body .chat-consent { gap: 9px; padding: 0 7px 8px; font-size: 10px; }
  .chat-page-body .chat-consent label { gap: 6px; }
  .chat-page-body .chat-form { gap: 5px; padding: 7px; border-radius: 21px; }
  .chat-page-body .image-upload { width: 42px; height: 42px; }
  .chat-page-body .chat-form textarea { min-height: 52px; padding: 12px 3px; font-size: 16px; }
  .chat-page-body #send-button { width: 42px; min-width: 42px; min-height: 42px; }
  .chat-page-body .chat-status { min-height: 22px; padding: 6px 8px 1px; }
  .chat-starters { gap: 7px; margin-top: 11px; }
  .chat-starters button { min-height: 68px; padding: 11px 12px; border-radius: 12px; }
  .chat-starters strong { font-size: 12px; line-height: 1.3; }
  .chat-starters span { display: none; }
  .chat-starters i { grid-row: 1; }
  .chat-grounding-note { display: none; }
  .chat-page-body.chat-has-conversation .chat-thread-inner { width: min(100% - 24px, 850px); }
  .chat-page-body.chat-has-conversation .messages { padding: 28px 2px 20px; }
  .chat-page-body.chat-has-conversation .chat-composer-stack { padding-bottom: max(10px, env(safe-area-inset-bottom)); }
  .chat-page-body .message { max-width: 94%; }
  .chat-page-body .message-user { max-width: 88%; }
  .chat-page-body .message-copy { font-size: 16px; }
}

@media (max-width: 390px), (max-height: 680px) {
  .chat-empty-state > img { width: 40px; height: 40px; }
  .chat-empty-state > span { display: none; }
  .chat-empty-state h1 { font-size: 29px; }
  .chat-starters button { min-height: 59px; padding: 9px 10px; }
  .chat-page-body .chat-consent span { display: -webkit-box; overflow: hidden; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
}
