/* Antonio portfolio: real work, readable defaults, progressive interaction. */
:root { --muted:#526a74; --modal:90; }
html[data-theme="dark"] { --muted:#a4bcc5; }
h1,h2,h3 { text-wrap:balance; }
.rv,.rv.in { opacity:1; transform:none; }
.wi { transform:none; }
#loader,.grain { display:none; }
.cur,.cur-dot { display:none; }
.lbl { letter-spacing:.06em; font-size:13px; margin-bottom:26px; }
.lbl>b { display:none; }
.sec-pad { padding:clamp(62px,7vw,108px) 0; }
section[id],.case-panel[id] { scroll-margin-top:90px; }
#hero { min-height:0; display:block; padding:132px 0 52px; overflow:visible; }
.hero-v2 { display:grid; grid-template-columns:minmax(0,1fr) minmax(0,1.06fr); gap:clamp(36px,5vw,88px); align-items:center; }
.hi-eyebrow { margin-bottom:24px; letter-spacing:.08em; font-size:12px; backdrop-filter:none; background:none; border:none; padding:0; }
.hi-name { font-size:clamp(56px,6.5vw,96px); letter-spacing:-.03em; line-height:1.08; }
.hi-name .lat { margin-top:12px; color:var(--ink-dim); font-size:16px; letter-spacing:.28em; }
.hero-statement { font-size:clamp(23px,2.25vw,34px); color:var(--ink); font-weight:500; line-height:1.42; margin:28px 0 18px; letter-spacing:-.02em; }
.hero-statement em { font-style:normal; color:var(--accent); }
.hi-desc { font-size:15px; max-width:49ch; line-height:1.85; }
.hero-actions { display:flex; flex-wrap:wrap; align-items:center; gap:22px; margin-top:30px; }
.action-primary,.action-secondary { display:inline-flex; align-items:center; justify-content:space-between; gap:24px; min-height:48px; font-size:14px; font-weight:600; }
.action-primary { background:var(--ink); color:var(--bg); padding:12px 22px; border-radius:6px; transition:background .2s; }
.action-primary:hover { background:var(--accent); color:white; }
.action-secondary { border-bottom:1px solid var(--line-strong); }
.action-secondary:hover { color:var(--accent); }
.hero-fields { display:flex; flex-wrap:wrap; gap:6px 18px; margin-top:24px; font-size:12px; color:var(--muted); }
.hero-fields span+span:before { content:'·'; margin-right:18px; }
.hero-visual { min-width:0; }
.hero-visual>img { display:block; width:100%; max-width:660px; height:auto; margin:auto; }
.hero-visual-links { display:flex; justify-content:space-between; gap:15px; margin:8px 30px 0; padding-top:20px; border-top:1px solid var(--line-strong); }
.hero-visual-links a { display:inline-flex; align-items:center; gap:22px; min-height:44px; font-size:14px; color:var(--ink); }
.hero-visual-links a:hover { color:var(--accent); }
.hero-visual-links a:focus-visible { outline:2px solid var(--accent); outline-offset:5px; }
#education .job::before { display:none; }
.resume-version { display:block; color:var(--muted); font-size:11px; line-height:1.7; margin-top:7px; }
.hero-impact { margin-top:52px; padding-top:22px; border-top:1px solid var(--line-strong); display:grid; grid-template-columns:.75fr repeat(3,1fr) 1.15fr; gap:24px; align-items:center; }
.hero-impact>p { font-size:13px; color:var(--ink); line-height:1.8; }
.hero-impact small { font-size:11px; color:var(--muted); }
.hero-impact a { display:block; }
.hero-impact b { display:block; font-size:clamp(22px,2.2vw,34px); font-weight:500; line-height:1.2; letter-spacing:-.02em; }
.hero-impact a:hover b { color:var(--accent); }
.hero-impact span { display:block; margin-top:7px; color:var(--ink-dim); font-size:12px; }
.hero-data-note { margin-top:20px; font-size:11px; color:var(--muted); }
.section-kicker { font-size:14px; margin-bottom:18px; color:var(--accent); }
.inv { --inv-muted:#abc0c7; }
html[data-theme="dark"] .inv { --inv-muted:#425c67; }
.inv::after { display:none; }
.inv .section-kicker { color:var(--inv-accent); }
.work-heading,.evidence-heading { display:flex; justify-content:space-between; align-items:end; gap:36px; }
.work-heading h2 { font-size:clamp(32px,4vw,54px); line-height:1.18; }
.work-heading>p,.evidence-heading>p { max-width:38ch; font-size:15px; line-height:1.8; }
.case-tabs { margin-top:42px; display:flex; border-top:1px solid var(--inv-line-strong); border-bottom:1px solid var(--inv-line-strong); }
.case-tabs a { display:block; flex:1; position:relative; padding:21px 16px 23px; color:var(--inv-dim); border-right:1px solid var(--inv-line); transition:color .2s,background .2s; }
.case-tabs a:first-child { padding-left:0; }
.case-tabs a:last-child { border-right:0; }
.case-tabs span { display:block; font-size:11px; margin-bottom:9px; color:var(--inv-muted); }
.case-tabs b { font-size:clamp(13px,1.2vw,17px); font-weight:500; }
.case-tabs i { display:none; font-style:normal; }
.case-tabs a[aria-selected="true"] { color:var(--inv-ink); background:var(--inv-card); }
.case-tabs a[aria-selected="true"]:after { content:''; position:absolute; height:2px; bottom:-1px; left:0; right:0; background:var(--inv-accent); }
.case-tabs a:hover { color:var(--inv-ink); }
.case-panel { padding-top:36px; outline-offset:8px; }
.case-panel[hidden] { display:none; }
.case-layout { display:grid; grid-template-columns:minmax(0,1.23fr) minmax(0,1fr); gap:clamp(26px,4vw,64px); align-items:start; }
.case-gallery,.case-copy { min-width:0; }
.gallery-meta { display:flex; align-items:center; justify-content:space-between; gap:12px; color:var(--inv-muted); font-size:11px; padding:0 0 12px; }
.gallery-index { font-variant-numeric:tabular-nums; }
.gallery-main { position:relative; display:flex; align-items:center; justify-content:center; overflow:hidden; aspect-ratio:1.62; background:#eef2f4; border-radius:8px; }
.gallery-main img { width:100%; height:100%; object-fit:contain; }
.gallery-expand { position:absolute; bottom:14px; right:14px; padding:8px 12px; background:#0f2630; color:#fff; font-size:11px; border-radius:5px; }
.gallery-main.is-diagram { background:#102931; }
.gallery-main.is-diagram .gallery-expand { top:14px; bottom:auto; }
.gallery-caption { display:flex; justify-content:space-between; gap:18px; align-items:center; margin-top:16px; }
.gallery-caption h4 { color:var(--inv-ink); font-size:15px; font-weight:500; margin-bottom:6px; }
.gallery-source { font-size:11px; color:var(--inv-muted)!important; }
.gallery-arrows { display:flex; gap:6px; flex-shrink:0; }
.gallery-arrows button { width:40px; height:40px; border:1px solid var(--inv-line-strong); border-radius:50%; color:var(--inv-ink); }
.gallery-arrows button:hover { background:var(--inv-card); }
.gallery-arrows button:disabled { opacity:.4; cursor:default; }
.gallery-thumbs { display:flex; gap:10px; margin-top:18px; }
.gallery-thumb { display:block; width:80px; height:49px; border:2px solid transparent; border-radius:4px; overflow:hidden; background:#eef2f4; }
.gallery-thumb img { width:100%; height:100%; object-fit:contain; }
.gallery-thumb[aria-current="true"] { border-color:var(--inv-accent); }
.gallery-main:focus-visible,.case-tabs a:focus-visible,.gallery-thumb:focus-visible { outline:2px solid var(--inv-accent); outline-offset:5px; }
.case-category { font-size:12px; color:var(--inv-accent)!important; margin:0 0 14px; }
.case-copy h3 { font-size:clamp(21px,2.1vw,30px); line-height:1.42; }
.case-summary { font-size:15px; margin-top:16px; }
.case-role { font-size:11px; color:var(--inv-muted)!important; margin-top:18px; line-height:1.8; }
.case-results { display:flex; flex-wrap:wrap; gap:15px 24px; margin-top:24px; padding-top:18px; border-top:1px solid var(--inv-line); }
.case-results .metric { padding:0; border:0; }
.case-results .metric b { font-size:clamp(22px,2.15vw,30px); font-weight:500; letter-spacing:-.02em; }
.case-results .metric span { font-size:11px; max-width:15ch; }
.case-point { margin-top:22px; font-size:13px; line-height:1.85; max-width:65ch; }
.case-contact { display:inline-flex; gap:32px; font-size:12px; color:var(--inv-accent); border-bottom:1px solid var(--inv-line-strong); padding:12px 0; margin-top:12px; }
.case-details { margin-top:28px; border-top:1px solid var(--inv-line); border-bottom:1px solid var(--inv-line); }
.case-details summary { display:flex; justify-content:space-between; gap:20px; list-style:none; padding:20px 0; color:var(--inv-ink); font-size:13px; cursor:pointer; }
.case-details summary::-webkit-details-marker { display:none; }
.case-details summary span { font-size:18px; line-height:1; }
.case-details[open] summary span { transform:rotate(45deg); }
.case-facts { padding-bottom:20px; }
.case-facts .fact { padding:16px 0; }
.case-facts .fact dd { font-size:13px; }
.evidence-heading h2 { font-size:clamp(28px,3.6vw,46px); line-height:1.25; }
.evidence-filters { display:flex; flex-wrap:wrap; gap:10px; margin:30px 0; }
.evidence-filters button { min-height:42px; padding:8px 18px; border:1px solid var(--line-strong); border-radius:100px; font-size:13px; color:var(--ink-dim); }
.evidence-filters button[aria-pressed="true"] { background:var(--ink); color:var(--bg); border-color:var(--ink); }
.evidence-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:32px; }
.evidence-item[hidden] { display:none; }
.evidence-image { position:relative; display:flex; width:100%; aspect-ratio:1.75; background:#e9edf0; border-radius:8px; overflow:hidden; }
.evidence-image img { height:100%; width:100%; object-fit:contain; }
.evidence-image>span { position:absolute; right:12px; bottom:12px; width:36px; height:36px; background:#0f2630; color:white; display:grid; place-items:center; border-radius:50%; }
.evidence-caption { padding:17px 0 20px; border-bottom:1px solid var(--line); }
.evidence-caption>span { font-size:11px; color:var(--muted); }
.evidence-caption h3 { font-size:18px; margin:7px 0; }
.evidence-caption p { font-size:12px; }
.tool[data-open-evidence],.tool[data-select-case] { cursor:pointer; min-height:44px; border-color:var(--line-strong); }
.tool[data-open-evidence] b:after,.tool[data-select-case] b:after { content:' ↗'; color:var(--accent); }
.kg-list-row a { display:inline-block; padding:5px 0; }
.kg-list-row a:hover { color:var(--accent); }
.image-viewer { width:min(94vw,1400px); max-width:none; height:94dvh; max-height:94dvh; margin:auto; padding:0; color:var(--ink); background:var(--bg); border:1px solid var(--line); border-radius:10px; overflow:hidden; }
.image-viewer::backdrop { background:rgba(0,12,18,.86); }
.image-viewer[open] { display:flex; flex-direction:column; }
.viewer-toolbar { display:flex; align-items:center; justify-content:space-between; gap:20px; padding:18px 24px; border-bottom:1px solid var(--line); flex-shrink:0; }
.viewer-toolbar h2 { font-size:19px; line-height:1.35; margin-top:4px; letter-spacing:0; }
.viewer-toolbar p { font-size:11px; color:var(--muted); }
.viewer-actions { display:flex; gap:10px; flex-shrink:0; }
.viewer-actions button,.viewer-footer>button { min-height:44px; border:1px solid var(--line-strong); border-radius:6px; padding:8px 15px; font-size:13px; }
.viewer-actions button:hover,.viewer-footer>button:hover { color:var(--accent); border-color:var(--accent); }
.viewer-canvas { min-height:0; flex:1; display:flex; align-items:center; justify-content:center; overflow:auto; padding:16px; background:#e5eaed; }
html[data-theme="dark"] .viewer-canvas { background:#132730; }
.viewer-canvas img { width:auto; height:auto; max-width:100%; max-height:100%; object-fit:contain; flex-shrink:0; cursor:zoom-in; }
.viewer-canvas.zoomed { display:block; }
.viewer-canvas.zoomed img { width:max(100%,1400px); max-width:none; max-height:none; cursor:zoom-out; }
.viewer-footer { display:flex; align-items:center; justify-content:space-between; gap:20px; padding:14px 24px; border-top:1px solid var(--line); flex-shrink:0; }
.viewer-footer>div { text-align:center; }
.viewer-footer p { font-size:12px; }
.viewer-footer span { display:block; font-size:11px; color:var(--muted); margin-top:4px; }
.viewer-footer button:disabled { opacity:.4; cursor:default; }
body.viewer-open { overflow:hidden; }
.sheet { overflow-y:auto; overscroll-behavior:contain; }
.sheet a { font-size:clamp(20px,5vw,28px); padding:10px 0; }
.sheet-foot { padding-bottom:25px; }
.resume-download:hover { color:var(--accent); }
@media(min-width:901px) { nav a { font-size:12px; } nav { gap:18px; } }
@media(max-width:1100px) {
  .hero-v2 { gap:30px; }.hero-statement { font-size:25px; }
  .hero-impact { grid-template-columns:.7fr repeat(3,1fr) 1.15fr; gap:15px; }
  .case-layout { grid-template-columns:minmax(0,1.1fr) minmax(0,1fr); gap:28px; }
  .case-tabs a { padding:20px 11px; }.case-tabs b { font-size:13px; }
  .case-copy h3 { font-size:23px; }
}
@media(max-width:900px) {
  nav { display:none; } #menuBtn { display:grid; }
  #hero { padding-top:110px; }.hero-v2 { grid-template-columns:1fr; gap:38px; }
  .hi-name { font-size:76px; }.hero-statement { font-size:30px; }
  .hi-desc { max-width:65ch; }.hero-visual { max-width:640px; }
  .hero-impact { grid-template-columns:repeat(4,1fr); }.hero-impact>p { grid-column:1/-1; }
  .work-heading,.evidence-heading { align-items:start; flex-direction:column; gap:22px; }
  .work-heading>p,.evidence-heading>p { max-width:62ch; }
  .case-layout { grid-template-columns:1fr; gap:26px; }.case-copy { max-width:75ch; }
  .case-tabs { flex-wrap:wrap; }.case-tabs a { flex:1 1 30%; padding:16px; }
  .case-tabs a:first-child { padding-left:16px; }.case-tabs a { border-bottom:1px solid var(--inv-line); }
  .case-tabs b { font-size:15px; }.case-tabs span { font-size:11px; }
  .case-results { gap:20px 35px; }.case-results .metric span { max-width:none; }
}
@media(max-width:600px) {
  :root { --pad:22px; }
  #hero { padding:100px 0 40px; }.hi-eyebrow { font-size:11px; margin-bottom:22px; }
  .hi-name { font-size:clamp(54px,16vw,72px); }.hi-name .lat { font-size:13px; }
  .hero-statement { font-size:25px; margin-top:26px; }.hi-desc { font-size:14px; }
  .hero-actions { gap:18px; margin-top:24px; }.hero-fields { display:none; }
  .hero-visual-links { margin:0; gap:10px; padding-top:12px; }
  .hero-visual-links a { font-size:12px; gap:8px; }
  .hero-impact { grid-template-columns:repeat(2,minmax(0,1fr)); gap:25px 15px; margin-top:32px; }
  .hero-impact b { font-size:27px; }.hero-impact span { font-size:11px; }
  .hero-impact>p { display:none; }.hero-data-note { font-size:10px; }
  .case-tabs { margin-top:28px; }.case-tabs a { flex:1 1 45%; padding:14px; }
  .case-tabs span { margin-bottom:6px; }.case-tabs b { font-size:14px; }
  .case-tabs a:last-child { flex-basis:100%; }.case-tabs a:last-child i { display:inline; float:right; }
  .case-tabs a:first-child { padding-left:14px; }
  .case-panel { padding-top:26px; }.case-copy h3 { font-size:22px; }
  .case-summary { font-size:14px; }.case-results { display:grid; grid-template-columns:1fr 1fr; gap:20px; }
  .case-results .metric b { font-size:26px; }.case-point { font-size:13px; }
  .case-facts .fact { grid-template-columns:1fr; gap:8px; }.case-facts .fact dt { font-size:12px; }
  .case-details summary { font-size:12px; }.gallery-source { font-size:10px; }
  .gallery-caption { gap:12px; }.gallery-caption h4 { font-size:14px; }.gallery-arrows button { width:36px; height:36px; }
  .evidence-grid { grid-template-columns:1fr; gap:25px; }.evidence-filters { gap:8px; }
  .evidence-filters button { padding:8px 13px; font-size:12px; }
  .image-viewer { width:100vw; height:100dvh; max-height:100dvh; border:0; border-radius:0; }
  .viewer-toolbar { padding:14px; align-items:start; gap:12px; }.viewer-toolbar h2 { font-size:15px; }
  .viewer-actions { gap:6px; }.viewer-actions button { padding:8px 10px; font-size:12px; }
  .viewer-footer { padding:12px 14px; gap:12px; }.viewer-footer p { font-size:10px; }
  .viewer-footer>button { padding:8px 12px; }.viewer-canvas { padding:8px; }
  .sheet { padding-top:90px; }
}
@media(prefers-reduced-motion:reduce) { .case-tabs a { transition:none; } html { scroll-behavior:auto; } }
.owner-entry { color:inherit; text-decoration:none; display:inline-block; padding:5px 1px; }
.owner-entry:hover { color:var(--accent); text-decoration:underline; text-underline-offset:4px; }
.owner-entry:focus-visible { outline:2px solid var(--accent); outline-offset:4px; border-radius:2px; }
/* Direct contact hierarchy: WeChat, phone, then email. */
.contact-direct{display:flex;flex-direction:column;align-items:flex-start;gap:0}
.contact-preferred{font-size:14px;color:var(--accent);margin-bottom:10px}
.contact-wechat{display:flex;align-items:baseline;flex-wrap:wrap;gap:10px 18px;background:none;border:0;border-bottom:1px solid var(--line);color:var(--ink);padding:0 0 12px;text-align:left;cursor:pointer;max-width:100%}
.contact-wechat>span:first-child{font-size:clamp(30px,3.7vw,54px);font-weight:600;letter-spacing:-.025em;font-variant-numeric:tabular-nums;user-select:text}
.contact-copy{font-size:13px;color:var(--accent);white-space:nowrap}
.contact-copy-status{font-size:12px;color:var(--muted);min-height:22px;margin:10px 0 22px}
.contact-phone,.contact-email{display:flex;gap:14px;align-items:baseline;text-decoration:none;max-width:100%;overflow-wrap:anywhere}
.contact-phone{font-size:clamp(21px,2vw,28px);margin-bottom:12px}
.contact-email{font-size:15px;color:var(--muted)}
.contact-phone>span:first-child,.contact-email>span:first-child{font-size:12px;color:var(--muted);flex-shrink:0}
.contact-wechat:hover,.contact-phone:hover,.contact-email:hover{color:var(--accent)}
.contact-direct :focus-visible{outline:2px solid var(--accent);outline-offset:5px}
@media(max-width:600px){.contact-wechat>span:first-child{font-size:clamp(29px,8.7vw,40px)}.contact-copy-status{margin-bottom:18px}.contact-email{font-size:14px}}

.owner-entry-top{order:2;font-size:12px;color:var(--ink-dim);padding:10px 4px;white-space:nowrap}.owner-entry-top:focus-visible{outline:2px solid var(--accent)}

#evidence[hidden]{display:none!important}
.kg-tooltip{position:fixed;z-index:1000;max-width:310px;padding:16px 18px;background:var(--bg,#f4f7f8);color:var(--ink,#102b35);border:1px solid #9cbcb7;box-shadow:0 8px 24px #00182018;border-radius:8px;font-size:14px;line-height:1.7;pointer-events:none}
.kg-description{padding:22px 28px;border-top:1px solid #b8cbcd;min-height:130px}
.kg-description h3{margin:0 0 8px;font-size:22px}.kg-description p{margin:0 0 10px;line-height:1.8}.kg-description a{color:#087961}.kg-node:focus{outline:none}.kg-node:focus circle{stroke:#087961;stroke-width:3px}.kg-list-row{cursor:pointer}

/* Native page section; shares the portfolio's typography, colors and spacing. */
.hero-identity { display:flex; gap:22px; align-items:center; }
.hero-avatar { display:block; width:88px; height:88px; flex:0 0 88px; border-radius:18px; object-fit:contain; }
.hero-identity .hi-name { min-width:0; }
.hero-identity .hi-name .lat { margin-top:12px; }
.hero-ask-link { display:inline-flex; align-items:center; gap:12px; min-height:44px; margin-top:14px; color:var(--accent); font-size:13px; }
.hero-ask-link svg { width:18px; height:18px; }
.profile-ask { border-top:1px solid var(--line); }
.ask-layout { display:grid; grid-template-columns:minmax(0,.85fr) minmax(0,1.15fr); gap:clamp(36px,6vw,88px); align-items:start; }
.ask-intro { min-width:0; }
.ask-avatar { display:block; width:78px; height:78px; object-fit:contain; border-radius:16px; margin-bottom:28px; }
.ask-intro h2 { font-size:clamp(34px,3.4vw,49px); line-height:1.28; margin:0 0 24px; letter-spacing:-.025em; }
.ask-intro>p { font-size:15px; color:var(--ink-dim); line-height:1.9; max-width:35ch; }
.ask-intro .ask-identity { font-size:12px; color:var(--muted); margin-top:20px; }
.ask-suggestions { display:flex; flex-direction:column; margin:30px 0 20px; }
.ask-suggestions button { display:flex; justify-content:space-between; gap:20px; text-align:left; min-height:50px; padding:13px 0; border-bottom:1px solid var(--line); color:var(--ink); font:inherit; font-size:14px; }
.ask-suggestions button:hover,.ask-contact:hover { color:var(--accent); }
.ask-suggestions button:disabled { color:var(--muted); cursor:wait; }
.ask-contact { display:inline-flex; align-items:center; gap:16px; font-size:12px; min-height:44px; color:var(--muted); }
.ask-conversation { min-width:0; border:1px solid var(--line-strong); border-radius:14px; background:var(--bg); overflow:hidden; }
.ask-top { display:flex; gap:16px; justify-content:space-between; align-items:center; padding:20px 24px; border-bottom:1px solid var(--line); }
.ask-top strong { display:block; font-size:14px; font-weight:600; color:var(--ink); }
.ask-top span { display:block; font-size:11px; color:var(--muted); margin-top:4px; }
.ask-top button { min-height:44px; color:var(--muted); font:inherit; font-size:12px; padding:5px 0 5px 12px; }
.ask-top button:hover { color:var(--accent); }
.ask-thread { height:365px; overflow-y:auto; overscroll-behavior:contain; padding:24px; scroll-behavior:smooth; scrollbar-color:var(--line-strong) transparent; scrollbar-width:thin; }
.ask-message { margin:0 0 24px; max-width:100%; }
.ask-speaker { display:block; color:var(--muted); font-size:11px; margin-bottom:8px; }
.ask-message p { color:var(--ink); font-size:14px; line-height:1.9; white-space:pre-wrap; overflow-wrap:anywhere; margin:0; }
.ask-answer { color:var(--ink); font-size:14px; line-height:1.85; overflow-wrap:anywhere; min-width:0; }
.ask-answer p { white-space:normal; line-height:1.85; margin:0 0 14px; }
.ask-answer>:last-child { margin-bottom:0; }
.ask-answer h1,.ask-answer h2,.ask-answer h3,.ask-answer h4,.ask-answer h5,.ask-answer h6 { color:var(--ink); font-size:16px; font-weight:600; line-height:1.5; letter-spacing:0; margin:22px 0 10px; }
.ask-answer>:first-child { margin-top:0; }
.ask-answer strong { font-weight:600; }
.ask-answer ul,.ask-answer ol { margin:12px 0 16px; padding-left:22px; }
.ask-answer li { padding-left:2px; margin:7px 0; }
.ask-answer li>p { margin:0 0 7px; }
.ask-answer blockquote { margin:16px 0; padding:12px 16px; border-left:1px solid var(--accent); background:var(--card); color:var(--ink-dim); }
.ask-answer blockquote p { color:inherit; }
.ask-answer code { font-family:Consolas,"SFMono-Regular",monospace; font-size:.88em; padding:2px 5px; border-radius:3px; background:var(--card); overflow-wrap:anywhere; }
.ask-answer pre { margin:16px 0; padding:14px 16px; border:1px solid var(--line); border-radius:6px; background:var(--card); overflow:auto; max-width:100%; scrollbar-width:thin; }
.ask-answer pre code { padding:0; white-space:pre; overflow-wrap:normal; background:none; font-size:12px; line-height:1.7; }
.ask-answer a { color:var(--accent); text-decoration:underline; text-underline-offset:3px; }
.ask-answer hr { margin:20px 0; border:0; border-top:1px solid var(--line); }
.ask-table-scroll { max-width:100%; overflow:auto; margin:16px 0; scrollbar-width:thin; }
.ask-answer table { width:100%; min-width:280px; border-collapse:collapse; font-size:12px; }
.ask-answer th,.ask-answer td { padding:9px 12px; text-align:left; border:1px solid var(--line); vertical-align:top; }
.ask-answer th { font-weight:600; background:var(--card); }
.ask-answer.is-plain { white-space:pre-wrap; }
.is-streaming .ask-answer:after { content:''; display:inline-block; width:2px; height:15px; margin-left:3px; background:var(--accent); vertical-align:text-bottom; }
.ask-user { margin-left:36px; padding:14px 18px; background:var(--card); border-radius:12px; }
.ask-user .ask-speaker { color:var(--ink-dim); }
.ask-related { display:flex; flex-wrap:wrap; gap:5px 16px; margin-top:14px; padding-top:10px; border-top:1px solid var(--line); }
.ask-related a { color:var(--accent); font-size:12px; line-height:1.7; padding:5px 0; }
.ask-status { margin:0 24px; min-height:27px; color:var(--muted); font-size:12px; line-height:1.8; overflow-wrap:anywhere; }
.ask-status.is-error { color:var(--ink); }
.ask-form { margin:6px 16px 0; padding:14px 14px 10px; border:1px solid var(--line-strong); border-radius:10px; }
.ask-form:focus-within { border-color:var(--accent); }
.ask-form textarea { display:block; width:100%; min-height:54px; max-height:180px; resize:vertical; font:inherit; font-size:14px; line-height:1.65; color:var(--ink); background:transparent; border:0; padding:0; outline:0; caret-color:var(--accent); }
.ask-form textarea::placeholder { color:var(--muted); }
.ask-form-bottom { display:flex; gap:12px; align-items:center; justify-content:flex-end; margin-top:9px; }
.ask-form-bottom>span { margin-right:auto; color:var(--muted); font-size:10px; }
.ask-form button { display:inline-flex; gap:10px; align-items:center; min-height:40px; padding:8px 15px; font:inherit; font-size:12px; }
#ask-send { color:var(--bg); background:var(--ink); border-radius:6px; }
#ask-send:hover { background:var(--accent); color:white; }
#ask-send:disabled { opacity:.5; cursor:wait; }
#ask-send svg { width:16px; height:16px; }
#ask-stop { color:var(--muted); padding-inline:4px; }
#ask-stop[hidden] { display:none; }
.ask-privacy { color:var(--muted); font-size:10px; line-height:1.85; padding:12px 24px 18px; margin:0; }
.ask-sr { position:absolute; width:1px; height:1px; overflow:hidden; clip-path:inset(50%); white-space:nowrap; }
.ask-noscript { font-size:12px; padding:0 24px 20px; }
.profile-ask button:focus-visible,.profile-ask a:focus-visible,.hero-ask-link:focus-visible { outline:2px solid var(--accent); outline-offset:4px; }
@media(max-width:1100px) { .hero-avatar { width:72px; height:72px; flex-basis:72px; }.hero-identity { gap:16px; }.hero-identity .hi-name { font-size:clamp(54px,6.8vw,85px); } }
@media(max-width:900px) { .ask-layout { grid-template-columns:1fr; gap:30px; }.ask-intro>p { max-width:60ch; }.ask-suggestions { margin-top:22px; max-width:540px; }.ask-thread { height:360px; } }
@media(max-width:600px) {
  .hero-avatar { width:66px; height:66px; flex-basis:66px; border-radius:13px; }.hero-identity { gap:15px; }.hero-identity .hi-name { font-size:clamp(48px,13vw,64px); }.hero-identity .hi-name .lat { margin-top:10px; font-size:12px; }
  .ask-avatar { width:66px; height:66px; margin-bottom:22px; }.ask-intro h2 { font-size:34px; }.ask-intro>p { font-size:14px; }
  .ask-top { padding:14px 18px; }.ask-thread { height:340px; padding:20px 18px; }.ask-message p { font-size:14px; }.ask-user { margin-left:18px; padding:12px 14px; }
  .ask-status { margin-inline:18px; }.ask-form { margin-inline:12px; padding:12px; }.ask-form textarea { font-size:16px; }.ask-form-bottom>span { display:none; }.ask-privacy { padding-inline:18px; font-size:11px; }
}
@media(prefers-reduced-motion:reduce) { .ask-thread { scroll-behavior:auto; } }

/* Keep portrait aligned to the Chinese name, independently of the Latin subtitle. */
.hero-identity{--identity-size:clamp(76px,8.4vw,132px);align-items:flex-start;gap:22px}
.hero-identity .hero-avatar{width:var(--identity-size);height:var(--identity-size);flex:0 0 var(--identity-size);border-radius:20%;margin-top:0}
.hero-identity .hi-name{font-size:var(--identity-size);line-height:1;margin-left:0}
@media(max-width:1100px){.hero-identity{--identity-size:clamp(54px,6.8vw,85px);gap:16px}}
@media(max-width:600px){.hero-identity{--identity-size:clamp(42px,12vw,64px);gap:14px}}

.ask-more summary{cursor:pointer;padding:12px 0;color:var(--accent);font-size:14px}.ask-more button{width:100%}.ask-more summary:focus-visible{outline:2px solid currentColor;outline-offset:4px}

#ask-lead[hidden]{display:none}#ask-lead p{font-size:14px;line-height:1.6;margin:8px 0}#ask-lead select,#ask-lead input:not([type=checkbox]),#ask-lead button{font:inherit;color:var(--text,#12303a);background:var(--bg,#f5f8f8);border:1px solid var(--line,#bacdd0);border-radius:6px;padding:8px 12px}#ask-lead input[type=checkbox]{accent-color:#007f70}#ask-lead button[type=submit]{background:#0d343c;color:white;margin-top:8px}#ask-lead label{font-size:14px}#ask-lead-status{color:#aa3e28}

.analytics-privacy{padding-block:20px 28px;color:var(--ink-dim);font-size:14px;line-height:1.7}
.analytics-privacy summary{cursor:pointer;display:list-item;width:fit-content;color:var(--ink);padding:6px 0;text-underline-offset:4px}
.analytics-privacy p{max-width:75ch;margin:8px 0}
.analytics-actions{display:flex;flex-wrap:wrap;gap:10px;align-items:center;margin-top:10px}
.analytics-actions button{font:inherit;background:transparent;cursor:pointer;padding:8px 13px;border:1px solid var(--line-strong);border-radius:8px;color:var(--ink);min-height:40px;transition:background .2s}
.analytics-actions button:hover{background:var(--accent-soft)}
.analytics-actions button:focus-visible,.analytics-privacy summary:focus-visible{outline:2px solid var(--accent);outline-offset:3px}
.analytics-status{color:var(--ink-dim)}
.analytics-privacy [hidden]{display:none!important}
.case-detail-link{display:inline-block;margin-top:18px;font-size:14px;text-decoration:underline;text-underline-offset:5px;color:var(--inv-accent)}
@media(max-width:600px){.analytics-privacy{font-size:14px}.analytics-actions{gap:8px}}

#analytics-notice{position:fixed;z-index:90;right:20px;bottom:20px;width:min(300px,calc(100vw - 32px));padding:14px 16px;background:var(--bg,#f5f8f8);color:var(--ink,#10252d);border:1px solid var(--line-strong,#c6d3d5);border-radius:12px;box-shadow:0 6px 28px #00182020;font:13px/1.5 system-ui,sans-serif}#analytics-notice[hidden]{display:none}#analytics-notice p{margin:5px 0;color:var(--ink-dim,#46616a)}#analytics-notice .analytics-actions{margin-top:8px}#analytics-notice button{min-height:36px;padding:5px 16px}#analytics-notice button:first-child{background:var(--accent,#087b68);color:#fff} @media(max-width:600px){#analytics-notice{right:12px;bottom:max(12px,env(safe-area-inset-bottom));width:270px}}

.hero-three-stage{position:relative;aspect-ratio:660/570;width:100%;max-width:none;margin:auto;isolation:isolate}.hero-three-stage canvas{display:block;width:100%;height:100%;cursor:grab;touch-action:pan-y}.hero-three-stage canvas.dragging{cursor:grabbing}.hero-three-stage canvas:focus-visible{outline:2px solid var(--accent);outline-offset:-4px}.hero-visual.three-ready>img{display:none}.hero-three-label{position:absolute;transform:translateY(-40%);display:flex;flex-direction:column;text-align:left;gap:3px;background:none;border:0;padding:5px 8px;color:var(--ink);cursor:pointer;border-radius:5px;white-space:nowrap;text-shadow:0 1px 2px var(--bg)}.hero-three-label strong{font-size:clamp(19px,2vw,28px);line-height:1.1;font-weight:650}.hero-three-label span{font-size:9px;letter-spacing:.14em;color:var(--ink-dim)}.hero-three-label:hover,.hero-three-label.selected{background:var(--bg);box-shadow:0 4px 12px #12333d14}.hero-three-label:focus-visible{outline:2px solid var(--accent)}.hero-visual-links a.three-selected{color:var(--accent);text-decoration:underline;text-underline-offset:5px}@media(max-width:600px){.hero-three-label{padding:3px}.hero-three-label strong{font-size:19px}.hero-three-label span{font-size:8px}}

@media(min-width:1000px){.hero-v2{grid-template-columns:minmax(0,.88fr) minmax(0,1.22fr);gap:32px}.hero-visual{max-width:none}#hero{padding-top:112px}.hero-three-stage{aspect-ratio:1.13}.hero-three-label strong{font-size:30px}.hero-three-label span{font-size:10px}}
@media(max-width:600px){.hero-three-stage{aspect-ratio:1.06}.hero-three-label strong{font-size:21px}}

@media(min-width:1000px){.hero-three-stage{aspect-ratio:1.08}}
.hero-three-stage[hidden]{display:none}

@media(min-width:1000px){.hero-visual-links{margin-left:12px;margin-right:12px}}

/* Identity supports the project navigator instead of dominating the screen. */
.hero-identity{--identity-size:clamp(58px,5.4vw,86px);gap:18px}.hero-identity .hi-name .lat{font-size:13px;letter-spacing:.25em;margin-top:12px}
.hero-project-pin{position:absolute;transform:translate(-50%,calc(-100% - 18px));white-space:nowrap;z-index:3;display:inline-flex;align-items:center;gap:9px;padding:9px 12px;background:rgba(255,255,255,.95);border:1px solid #b3d7cd;border-radius:5px;color:#133c38;font:500 12px/1.3 system-ui,sans-serif;box-shadow:0 5px 16px #133d4210;text-decoration:none;transition:background .16s,box-shadow .16s}
.hero-project-pin:after{content:'↗';color:#158873}.hero-project-pin:before{content:'';position:absolute;top:100%;left:50%;height:18px;width:1px;background:#4a9e8b}.hero-project-pin[data-layer="1"]{border-color:#b6cbed;color:#344878}.hero-project-pin[data-layer="2"]{border-color:#b4d6e5;color:#27556f}.hero-project-pin:hover,.hero-project-pin.is-highlighted{background:#e3fff5;box-shadow:0 7px 22px #10584422}.hero-project-pin:focus-visible{outline:2px solid #009f80;outline-offset:3px}
html[data-theme="dark"] .hero-project-pin{background:#183d49;color:#d8f3ec;border-color:#538778}html[data-theme="dark"] .hero-project-pin:hover{background:#245261}
@media(max-width:600px){.hero-identity{--identity-size:clamp(42px,11.5vw,56px);gap:14px}.hero-project-pin{padding:7px 8px;font-size:10px;gap:4px;transform:translate(-50%,calc(-100% - 12px))}.hero-project-pin:before{height:12px}.hero-three-label strong{font-size:18px}.hero-three-label span{font-size:7px}.hero-identity .hi-name .lat{font-size:11px}}
@media(prefers-reduced-motion:reduce){.hero-project-pin{transition:none}}

.hero-project-pin{transform:none}.hero-project-pin:before{display:none}a.hero-project-pin:after{content:'↗'}.hero-project-pin.is-label:after{display:none}.hero-project-pin.is-label{cursor:default}.hero-project-connectors{position:absolute;inset:0;width:100%;height:100%;pointer-events:none;overflow:visible;z-index:2}.hero-project-connectors path{fill:none;stroke:#509f94;stroke-width:1;opacity:.75}
@media(max-width:600px){.hero-project-pin{transform:none;padding:5px 6px;font-size:9px;gap:3px}}

/* Keep the 3D viewport independent of page scroll width, including offscreen resize. */
.hero-three-stage{overflow:hidden}

.aigc-sample{margin:0 0 20px;min-width:0}.aigc-sample video{display:block;width:100%;aspect-ratio:16/9;object-fit:contain;background:#061318;border-radius:8px}.aigc-sample figcaption{font-size:13px;line-height:1.6;margin-top:10px;color:inherit}.case-media{min-width:0}.aigc-materials{border-top:1px solid currentColor;padding-top:14px}.aigc-materials>summary{cursor:pointer;font-size:14px;margin-bottom:16px}.case-page>.aigc-sample{max-width:960px;margin:24px auto 40px}.aigc-sample video:focus-visible{outline:2px solid #08ae8c;outline-offset:4px}
