@charset "UTF-8";
/* Shared visual system for the teacher and student zones: a works-first gallery, light or dark.
   Theme follows the system unless the visitor picks one (html[data-theme]). Page-specific files only add layout. */
:root{
  --z-bg:#f5f4f0;--z-bar:rgba(245,244,240,.88);--z-surface:#fff;--z-surface-2:#eeede8;--z-surface-3:#e5e4de;
  --z-text:#161b19;--z-text-2:#57615c;--z-text-3:#636c67;--z-line:rgba(22,27,25,.09);--z-line-2:rgba(22,27,25,.16);
  --z-chip:#fff;--z-pill:#161b19;--z-pill-text:#fff;--z-pill-hover:#2c3430;--z-accent:#86622a;--z-accent-soft:rgba(148,109,47,.1);
  --z-good:#2f7a5c;--z-good-soft:rgba(47,122,92,.1);--z-danger:#b0473a;--z-focus:#b07a3c;
  --z-shadow:0 1px 0 rgba(22,27,25,.04),0 6px 18px rgba(22,27,25,.06);--z-shadow-lift:0 16px 36px rgba(22,27,25,.13);
  --z-fade:245,244,240;--z-logo:none;--z-ease:cubic-bezier(.22,.68,.25,1);--z-radius:14px;--z-radius-sm:10px;
  color-scheme:light;font-family:"Microsoft YaHei","PingFang SC",system-ui,sans-serif;font-synthesis:none
}
@media (prefers-color-scheme:dark){:root:not([data-mode]){
  --z-bg:#0e1311;--z-bar:rgba(14,19,17,.86);--z-surface:#161d1a;--z-surface-2:#1c2521;--z-surface-3:#25302b;
  --z-text:#e8ece9;--z-text-2:#a9b3ae;--z-text-3:#8a948f;--z-line:rgba(255,255,255,.08);--z-line-2:rgba(255,255,255,.16);
  --z-chip:rgba(255,255,255,.06);--z-pill:#f2f4f2;--z-pill-text:#0e1311;--z-pill-hover:#fff;--z-accent:#d7b77a;--z-accent-soft:rgba(215,183,122,.12);
  --z-good:#6cc59c;--z-good-soft:rgba(108,197,156,.12);--z-danger:#e58a7c;--z-focus:#d7b77a;
  --z-shadow:0 1px 0 rgba(255,255,255,.03);--z-shadow-lift:0 16px 36px rgba(0,0,0,.45);--z-fade:14,19,17;--z-logo:brightness(0) invert(1);color-scheme:dark}}
/* zone.js writes the resolved theme (system or chosen) to data-mode before the page paints. */
:root[data-mode=dark]{
  --z-bg:#0e1311;--z-bar:rgba(14,19,17,.86);--z-surface:#161d1a;--z-surface-2:#1c2521;--z-surface-3:#25302b;
  --z-text:#e8ece9;--z-text-2:#a9b3ae;--z-text-3:#8a948f;--z-line:rgba(255,255,255,.08);--z-line-2:rgba(255,255,255,.16);
  --z-chip:rgba(255,255,255,.06);--z-pill:#f2f4f2;--z-pill-text:#0e1311;--z-pill-hover:#fff;--z-accent:#d7b77a;--z-accent-soft:rgba(215,183,122,.12);
  --z-good:#6cc59c;--z-good-soft:rgba(108,197,156,.12);--z-danger:#e58a7c;--z-focus:#d7b77a;
  --z-shadow:0 1px 0 rgba(255,255,255,.03);--z-shadow-lift:0 16px 36px rgba(0,0,0,.45);--z-fade:14,19,17;--z-logo:brightness(0) invert(1);color-scheme:dark}

/* ---------- Base ---------- */
*{box-sizing:border-box}
html{scroll-behavior:smooth;scroll-padding-top:90px;scrollbar-gutter:stable}
body{margin:0;background:var(--z-bg);color:var(--z-text);font-size:14px;line-height:1.7;transition:background .4s,color .4s}
button,input,textarea,select{font:inherit;color:inherit}
button{cursor:pointer;border:0;background:none;padding:0}
button:disabled{cursor:not-allowed;opacity:.5}
a{color:inherit;text-decoration:none}
img,video,svg{display:block;max-width:100%}
h1,h2,h3,h4,p{margin:0}
h1,h2,h3{line-height:1.4;font-weight:700}
[hidden]{display:none!important}
a:focus-visible,button:focus-visible,input:focus-visible,textarea:focus-visible,select:focus-visible,summary:focus-visible{outline:2px solid var(--z-focus);outline-offset:3px}
.sr-only{position:absolute!important;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
.skip{position:fixed;top:-100px;left:20px;z-index:100;background:var(--z-pill);color:var(--z-pill-text);padding:10px 16px;border-radius:8px}.skip:focus{top:10px}
.no-script{padding:40px;text-align:center}

/* ---------- Shell: top bar, sub bar, footer ---------- */
.z-top{position:sticky;top:0;z-index:30;height:64px;display:flex;align-items:center;gap:22px;padding:0 clamp(16px,3vw,40px);background:var(--z-bar);backdrop-filter:blur(14px);-webkit-backdrop-filter:blur(14px);border-bottom:1px solid var(--z-line)}
.z-brand{flex-shrink:0;width:196px}
.z-brand img{width:100%;height:auto;filter:var(--z-logo)}
.z-zone{font-size:14px;font-weight:700;padding-left:20px;border-left:1px solid var(--z-line-2);white-space:nowrap}
.z-nav{display:flex;align-items:center;gap:4px;margin-left:10px}
.z-nav a{display:flex;align-items:center;height:36px;padding:0 14px;border-radius:18px;font-size:14px;color:var(--z-text-2);white-space:nowrap;transition:color .2s,background .2s}
.z-nav a:hover{color:var(--z-text)}
.z-nav a[aria-current=page]{color:var(--z-text);font-weight:700;background:var(--z-chip);box-shadow:inset 0 0 0 1px var(--z-line)}
.z-nav .z-nav-extra{display:none}
.z-actions{margin-left:auto;display:flex;align-items:center;gap:10px}
.z-quiet{font-size:13px;color:var(--z-text-2);white-space:nowrap;padding:0 6px}
.z-quiet:hover{color:var(--z-text)}
.z-icon-btn{display:inline-grid;place-items:center;width:36px;height:36px;border-radius:50%;border:1px solid var(--z-line);background:var(--z-chip);color:var(--z-text);flex-shrink:0}
.z-icon-btn svg{width:17px;height:17px;stroke:currentColor;fill:none;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}
.z-icon-btn:hover{border-color:var(--z-line-2)}
.z-avatar{width:36px;height:36px;border-radius:50%;background:var(--z-surface-3);color:var(--z-text);font-size:13px;font-weight:700;flex-shrink:0}
.z-menu{display:none}
.z-main{max-width:1480px;margin:0 auto;padding:0 clamp(16px,3vw,40px);outline:0;min-height:calc(100dvh - 64px);display:flex;flex-direction:column}
#view{flex:1}
.workspace-bar{display:flex;align-items:center;justify-content:space-between;gap:14px;padding:18px 0 4px;font-size:12px;color:var(--z-text-3)}
.workspace-bar>p{display:flex;align-items:center;gap:8px}
.online-dot{width:6px;height:6px;border-radius:50%;background:var(--z-good)}
.bar-divider{opacity:.5}
.stage-control{display:flex;gap:2px;padding:3px;border-radius:20px;background:var(--z-chip);border:1px solid var(--z-line)}
.stage-control[hidden]{display:none}
.stage-control button{height:30px;padding:0 14px;border-radius:15px;font-size:13px;color:var(--z-text-2)}
.stage-control button[aria-pressed=true]{background:var(--z-pill);color:var(--z-pill-text);font-weight:600}
.space-footer{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:12px 24px;margin-top:64px;padding:22px 0 30px;border-top:1px solid var(--z-line);font-size:12px;color:var(--z-text-3)}
.space-footer p span{margin:0 6px}
.footer-actions{display:flex;flex-wrap:wrap;gap:6px 18px;align-items:center}
.footer-actions a,.footer-actions button{font-size:12px;color:var(--z-text-2)}
.footer-actions a:hover,.footer-actions button:hover{color:var(--z-text)}

/* ---------- Buttons, links, labels ---------- */
.button{display:inline-flex;align-items:center;justify-content:center;gap:10px;height:42px;padding:0 20px;border-radius:21px;font-size:14px;font-weight:600;background:var(--z-chip);color:var(--z-text);border:1px solid var(--z-line-2);white-space:nowrap;transition:background .2s,transform .2s,box-shadow .2s}
.button:hover{transform:translateY(-1px)}
.button.primary,.z-pill{background:var(--z-pill);color:var(--z-pill-text);border-color:transparent}
.button.primary:hover,.z-pill:hover{background:var(--z-pill-hover);box-shadow:var(--z-shadow-lift)}
.z-pill{display:inline-flex;align-items:center;gap:8px;height:38px;padding:0 18px;border-radius:19px;font-size:13px;font-weight:700;white-space:nowrap;transition:background .2s,box-shadow .2s}
.button.full{width:100%}
.button span[aria-hidden],.z-pill span[aria-hidden]{font-size:15px}
.text-link{display:inline-flex;align-items:center;gap:8px;font-size:13px;font-weight:600;color:var(--z-text);min-height:32px}
.text-link:hover{color:var(--z-accent)}
.text-link>span[aria-hidden]{transition:transform .25s}
.text-link:hover>span[aria-hidden]{transform:translate(2px,-2px)}
.eyebrow{font-size:12px;color:var(--z-accent);font-weight:600;letter-spacing:.5px}
.muted{color:var(--z-text-2)}
.fine-print,.storage-notice,.gallery-note,.guide-provenance{font-size:12px;color:var(--z-text-3);line-height:1.8}
.section-note{padding:40px 0;color:var(--z-text-3)}
.form-error{color:var(--z-danger);font-size:13px;min-height:1.4em}
.required-mark{color:var(--z-danger);font-weight:600}
.required-hint{font-size:12px;color:var(--z-text-3);margin-bottom:6px}
.example-note,.count{font-size:12px;color:var(--z-text-3)}

/* ---------- Page headings ---------- */
.page-heading{margin:28px 0 30px;max-width:780px}
.page-heading h1{font-size:clamp(28px,2.6vw,38px);letter-spacing:-.5px;margin-bottom:10px}
.page-heading p:not(.eyebrow){font-size:14px;color:var(--z-text-2);line-height:1.9}
.page-heading .eyebrow{margin-bottom:8px}
.section-head{display:flex;align-items:flex-end;justify-content:space-between;gap:16px;margin-bottom:16px}
.section-head h2{font-size:20px}
.section-head .eyebrow{margin-bottom:4px}
.z-section{padding-top:44px}
.z-section-head{display:flex;align-items:flex-end;justify-content:space-between;gap:16px;margin-bottom:18px}
.z-section-head h2{font-size:32px;letter-spacing:-.3px}
.z-section-head>span{font-size:12px;color:var(--z-text-3);white-space:nowrap}

/* ---------- Chips, segmented controls ---------- */
.scope-switch,.z-seg{display:inline-flex;gap:2px;padding:3px;border-radius:21px;background:var(--z-chip);border:1px solid var(--z-line)}
.scope-switch button,.z-seg button{height:32px;padding:0 15px;border-radius:16px;font-size:13px;color:var(--z-text-2);white-space:nowrap}
.scope-switch button[aria-pressed=true],.z-seg button[aria-pressed=true]{background:var(--z-pill);color:var(--z-pill-text);font-weight:600}
.filter-row,.z-chips{display:flex;flex-wrap:wrap;align-items:center;gap:8px}
.filter-row button,.z-chips button{height:34px;padding:0 16px;border-radius:17px;background:var(--z-chip);border:1px solid var(--z-line);font-size:13px;color:var(--z-text-2);transition:border-color .2s,color .2s}
.filter-row button:hover,.z-chips button:hover{color:var(--z-text);border-color:var(--z-line-2)}
.filter-row button[aria-pressed=true],.z-chips button[aria-pressed=true]{background:var(--z-pill);color:var(--z-pill-text);border-color:transparent;font-weight:600}
.filter-row .count{margin-left:auto}
.z-tabs{display:flex;gap:4px;border-bottom:1px solid var(--z-line);margin-bottom:24px;overflow-x:auto;scrollbar-width:none}
.z-tabs button{position:relative;height:44px;padding:0 16px;font-size:15px;color:var(--z-text-2);white-space:nowrap}
.z-tabs button[aria-selected=true]{color:var(--z-text);font-weight:700}
.z-tabs button[aria-selected=true]::after{content:"";position:absolute;left:14px;right:14px;bottom:-1px;height:2px;border-radius:2px;background:var(--z-text)}

/* ---------- Gallery: featured work, search bar, cards ---------- */
.z-feature{position:relative;margin:18px 0 8px;border-radius:20px;overflow:hidden;height:440px;background:var(--z-surface-2)}
.z-feature video,.z-feature>img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover}
.z-feature::after{content:"";position:absolute;inset:0;background:linear-gradient(90deg,rgba(var(--z-fade),1) 0%,rgba(var(--z-fade),.82) 30%,rgba(var(--z-fade),0) 62%),linear-gradient(0deg,rgba(var(--z-fade),.9) 0%,rgba(var(--z-fade),0) 30%);pointer-events:none}
.z-feature-copy{position:absolute;z-index:2;left:clamp(20px,3vw,40px);bottom:44px;max-width:460px}
.z-feature-copy .eyebrow{display:block;margin-bottom:8px}
.z-feature-copy h1,.z-feature-copy h2{font-size:clamp(30px,3vw,44px);letter-spacing:-1px;line-height:1.25;margin-bottom:12px}
.z-feature-copy p{font-size:14px;color:var(--z-text-2);line-height:1.9}
.z-feature-actions{display:flex;flex-wrap:wrap;gap:10px;margin-top:20px}
/* Light: the work sits in a framed card beside the text. Dark: it fills the frame and the text rests on it. */
:root:not([data-mode=dark]) .z-feature{background:none;overflow:visible}
:root:not([data-mode=dark]) .z-feature::after{display:none}
:root:not([data-mode=dark]) .z-feature video,:root:not([data-mode=dark]) .z-feature>img{inset:0 0 0 auto;width:62%;border-radius:20px;box-shadow:var(--z-shadow-lift)}
:root:not([data-mode=dark]) .z-feature-copy{top:50%;bottom:auto;transform:translateY(-50%);left:0;max-width:34%}

.z-gallery-head{display:flex;align-items:flex-end;justify-content:space-between;gap:24px;margin:34px 0 18px;flex-wrap:wrap}
.z-gallery-head h1{font-size:32px;letter-spacing:-.4px}
.z-gallery-head p{font-size:14px;color:var(--z-text-2);margin-top:4px}
.z-gallery-head .gallery-search{flex:0 1 340px}
.z-gallery-tools{display:flex;align-items:center;gap:10px;flex-wrap:wrap}
.z-gallery-count{display:flex;align-items:center;gap:16px;margin:0 0 14px}
.gallery-searchbar{display:flex;align-items:center;gap:12px;margin:26px 0 16px}
.gallery-search{flex:1;position:relative;display:block}
.gallery-search input{width:100%;height:44px;border-radius:22px;border:1px solid var(--z-line);background:var(--z-chip);padding:0 18px 0 44px;font-size:14px;color:var(--z-text);outline:0;transition:border-color .2s}
.gallery-search input:focus{border-color:var(--z-line-2)}
.search-symbol{position:absolute;left:16px;top:50%;width:18px;height:18px;transform:translateY(-50%);color:var(--z-text-3)}
.gallery-publish{height:44px;border-radius:22px}
.gallery-submit{white-space:nowrap}
.gallery-toolbar{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap;margin-bottom:14px}
.gallery-topic{min-width:180px}
.gallery-toolbar .filter-row{margin:0}
/* Gallery filters (gallery.js): domain and subject pills with counts, then selects, then the active filters. */
/* Top switches: work source (platform/teacher/student) and stage. */
.gf-lens{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:12px;margin:0 0 16px;padding-bottom:16px;border-bottom:1px solid var(--z-line)}
.gf-seg{display:inline-flex;gap:2px;padding:3px;border-radius:21px;background:var(--z-surface-2)}
.gf-seg button{height:34px;padding:0 16px;border-radius:17px;background:transparent;font-size:13px;color:var(--z-text-2);white-space:nowrap;transition:background .2s,color .2s,box-shadow .2s}
.gf-seg button:hover{color:var(--z-text)}
.gf-seg button[aria-pressed=true]{background:var(--z-chip);color:var(--z-text);font-weight:600;box-shadow:0 0 0 1px var(--z-line),0 1px 3px rgba(22,27,25,.08)}
.gf-seg button.gf-zero:not([aria-pressed=true]){color:var(--z-text-3)}
.gf-row{margin-bottom:10px}
.gf-row button{display:inline-flex;align-items:center;gap:6px;white-space:nowrap}
.gf-sub button{height:30px;padding:0 13px;font-size:12.5px}
.gf-row button.gf-zero:not([aria-pressed=true]){opacity:.5}
.gf-n{font-size:11px;font-weight:400;opacity:.62;font-variant-numeric:tabular-nums}
.gf-tools{display:flex;flex-wrap:wrap;gap:8px;margin:14px 0 12px}
.gf-select{flex:0 1 168px;min-width:136px}
.gf-select .select-trigger{min-height:38px;border-radius:19px;background:var(--z-chip);font-size:13px;padding:0 14px 0 16px}
.gf-select .select-options{min-width:220px}
.gf-active{display:flex;flex-wrap:wrap;align-items:center;gap:8px;margin:0 0 12px}
.gf-active button:not(.text-link){display:inline-flex;align-items:center;gap:6px;height:28px;padding:0 10px 0 12px;border-radius:14px;background:var(--z-accent-soft);color:var(--z-text);font-size:12.5px}
.gf-active button:not(.text-link) span{color:var(--z-text-3)}
.gf-active .text-link{font-size:12.5px}
.gf-empty .empty-art{font-size:30px}
.gf-relax{display:flex;flex-wrap:wrap;justify-content:center;gap:8px;margin-top:4px}
.works-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(280px,100%),1fr));gap:26px 20px}
.gallery-card{position:relative;min-width:0}
.work-card{display:block;color:inherit}
.work-cover{position:relative;display:block;aspect-ratio:16/10;border-radius:var(--z-radius);overflow:hidden;background:var(--z-surface-2);box-shadow:var(--z-shadow);transition:box-shadow .3s,transform .3s}
.work-cover>img,.work-cover>video{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;object-position:center top}
.work-cover>img{transition:transform .8s var(--z-ease),opacity .3s}
.work-cover>video{opacity:0;transition:opacity .35s}
.work-cover.is-previewing>video{opacity:1}
.work-card:hover .work-cover{box-shadow:var(--z-shadow-lift)}
.work-card:hover .work-cover>img{transform:scale(1.04)}
.work-tag{position:absolute;top:10px;left:10px;z-index:2;font-size:11px;font-weight:600;padding:3px 9px;border-radius:10px;background:rgba(255,255,255,.9);color:#161b19;backdrop-filter:blur(6px)}
.guide-badge{position:absolute;top:10px;right:10px;z-index:2;font-size:11px;font-weight:600;padding:3px 9px;border-radius:10px;background:rgba(14,19,17,.7);color:#fff;backdrop-filter:blur(6px)}
.duration{position:absolute;right:10px;bottom:10px;z-index:2;font-size:11px;padding:2px 8px;border-radius:8px;background:rgba(0,0,0,.6);color:#fff;font-variant-numeric:tabular-nums}
.cover-enter{position:absolute;left:10px;bottom:10px;z-index:2;width:30px;height:30px;border-radius:50%;display:grid;place-items:center;background:rgba(255,255,255,.92);color:#161b19;font-size:12px;opacity:0;transform:translateY(4px);transition:.25s}
.work-card:hover .cover-enter,.work-cover.is-previewing .cover-enter{opacity:1;transform:none}
.cover-placeholder{position:absolute;inset:0;display:grid;place-content:center;justify-items:center;gap:6px;color:var(--z-text-3);background:var(--z-surface-2)}
.cover-placeholder span{font-size:28px}.cover-placeholder small{font-size:12px}
.work-body{display:block;padding:12px 2px 0}
.work-body h3{font-size:15px;font-weight:700;line-height:1.5;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.work-category{display:block;font-size:12px;color:var(--z-text-3);margin-bottom:2px}
.work-meta{display:flex;flex-wrap:wrap;align-items:center;gap:4px 10px;margin-top:4px;font-size:12px;color:var(--z-text-3)}
.submit-tag{color:var(--z-accent);font-weight:600}
.manage-menu{position:absolute;top:8px;right:8px;z-index:3}
.manage-menu summary{list-style:none;cursor:pointer;font-size:12px;padding:4px 10px;border-radius:12px;background:rgba(14,19,17,.72);color:#fff}
.manage-menu summary::-webkit-details-marker{display:none}
.manage-menu>div{position:absolute;right:0;top:32px;min-width:150px;padding:6px;border-radius:12px;background:var(--z-surface);border:1px solid var(--z-line);box-shadow:var(--z-shadow-lift);display:grid}
.manage-menu>div button{text-align:left;padding:8px 10px;border-radius:8px;font-size:13px}
.manage-menu>div button:hover{background:var(--z-surface-2)}
.load-more{margin:26px auto 0;display:flex}
/* In-page trial of a web work (platform pages, or uploaded pages in a sandbox). */
.t-preview{position:relative;border-radius:18px;overflow:hidden;background:var(--z-surface-2);box-shadow:var(--z-shadow)}
.t-preview>img{width:100%;height:auto;aspect-ratio:1.6;object-fit:cover;object-position:top}
.t-preview-cta{position:absolute;left:16px;bottom:16px;display:flex;flex-wrap:wrap;gap:10px}
.t-preview-cta .button:not(.primary){background:rgba(255,255,255,.92);color:#161b19;border-color:transparent;backdrop-filter:blur(6px)}
.t-preview.is-live{background:var(--z-surface);width:100%}
.t-frame.t-frame-wide{height:auto;aspect-ratio:16/10}
.t-live-bar{display:flex;justify-content:space-between;align-items:center;gap:12px;padding:8px 16px;border-bottom:1px solid var(--z-line);font-size:12px;color:var(--z-text-2)}
.t-live-bar span{display:flex;align-items:center;gap:8px}
.t-live-bar i{width:7px;height:7px;border-radius:50%;background:var(--z-good)}
.t-frame{display:block;width:100%;height:640px;border:0;background:#fff}
.t-frame-sandboxed{height:680px;resize:vertical}
.t-detail-media{display:block;min-height:0}
.t-detail-media .t-preview{border-radius:0;box-shadow:none}
.t-local-html{min-height:300px;display:grid;place-items:center}
.t-local-html .t-preview-cta{position:static;flex-direction:column;align-items:center;padding:40px 20px;text-align:center}
.t-local-html.is-live{display:block;min-height:0}
.t-html-mark{font-size:30px;color:var(--z-text-3)}
.t-local-html p{font-size:13px;color:var(--z-text-2)}
.gallery-note{margin-top:28px}
.empty-state{border:1px dashed var(--z-line-2);border-radius:var(--z-radius);padding:54px 20px;text-align:center;display:grid;justify-items:center;gap:10px}
.empty-art{font-size:26px;color:var(--z-text-3)}
.empty-state h2{font-size:19px}
.empty-state p{font-size:13px;color:var(--z-text-2);max-width:460px}
.empty-state .button{margin-top:8px}

/* ---------- Work detail ---------- */
.detail-back{display:flex;justify-content:space-between;align-items:center;gap:12px;margin:22px 0 18px;font-size:13px;color:var(--z-text-3)}
.detail-back a{color:var(--z-text-2);font-weight:600}.detail-back a:hover{color:var(--z-text)}
.work-detail-layout{display:grid;grid-template-columns:minmax(0,1fr) 340px;gap:32px;align-items:start}
.detail-media{border-radius:18px;overflow:hidden;background:var(--z-surface-2);min-height:260px;display:grid;place-items:center}
.detail-media>img{width:100%;max-height:640px;object-fit:contain}
.detail-media>video{width:100%;aspect-ratio:16/9;background:#000;display:block}
.detail-media>audio{width:calc(100% - 40px);margin:70px 20px}
.media-loading{color:var(--z-text-3);font-size:13px}
.work-story{margin-top:22px;max-width:760px}
.work-story>p:not(.eyebrow){font-size:14px;color:var(--z-text-2);line-height:1.95;margin-top:6px}
.work-story .text-link{margin-top:10px}
.work-detail-aside{position:sticky;top:84px;display:grid;gap:12px;padding:22px;border-radius:18px;background:var(--z-surface);border:1px solid var(--z-line)}
.work-detail-aside h1{font-size:24px;letter-spacing:-.3px}
.author-line{display:flex;align-items:center;gap:10px;padding:12px 0;border-top:1px solid var(--z-line);border-bottom:1px solid var(--z-line)}
.author-line>span{width:36px;height:36px;border-radius:50%;background:var(--z-surface-3);display:grid;place-items:center;font-weight:700;font-size:13px;flex-shrink:0}
.author-line strong{display:block;font-size:14px}.author-line small{display:block;font-size:12px;color:var(--z-text-3)}
.no-guide{padding:12px 14px;border-radius:12px;background:var(--z-surface-2);font-size:13px;color:var(--z-text-2);display:grid;gap:4px}
.no-guide small{font-size:11px;color:var(--z-text-3)}
.detail-source-note{font-size:12px;color:var(--z-text-3);line-height:1.8}
.external-work,.download-file{display:grid;justify-items:center;gap:10px;padding:40px 20px;text-align:center}
.external-work>span,.download-file>span{font-size:28px;color:var(--z-text-3)}
.external-work h2{font-size:18px}.external-work p,.download-file p{font-size:13px;color:var(--z-text-2)}
.comments-section{margin-top:48px;padding-top:28px;border-top:1px solid var(--z-line);max-width:860px}
.comments-section>.muted{font-size:13px;margin-bottom:14px}
.comments-section form{display:grid;gap:10px;margin-bottom:22px}
.comments-section form>div{display:flex;justify-content:space-between;align-items:center;gap:12px}
.comments-section textarea{width:100%;border:1px solid var(--z-line);border-radius:12px;background:var(--z-surface);padding:12px 14px;resize:vertical;font-size:14px;line-height:1.8;outline:0}
.comments-section textarea:focus{border-color:var(--z-line-2)}
.comment{display:grid;grid-template-columns:34px 1fr;gap:12px;padding:14px 0;border-top:1px solid var(--z-line)}
.comment-avatar{width:34px;height:34px;border-radius:50%;background:var(--z-surface-3);display:grid;place-items:center;font-size:13px;font-weight:700}
.comment header{display:flex;gap:10px;align-items:baseline;font-size:13px}.comment header span{font-size:12px;color:var(--z-text-3)}
.comment p{font-size:14px;color:var(--z-text-2);margin-top:2px}
.comment-empty{font-size:13px;color:var(--z-text-3);padding:12px 0}

/* ---------- Creation guide ---------- */
.guide-heading{margin:10px 0 26px;max-width:820px}
.guide-heading h1{font-size:clamp(26px,2.4vw,34px);margin:6px 0}
.guide-byline{font-size:13px;color:var(--z-text-3)}
.guide-layout{display:grid;grid-template-columns:minmax(0,1fr) 320px;gap:32px;align-items:start}
.guide-block{display:grid;grid-template-columns:36px minmax(0,1fr);gap:14px;padding:22px 0;border-top:1px solid var(--z-line)}
.guide-step,.z-step{width:28px;height:28px;border-radius:50%;background:var(--z-surface-2);color:var(--z-text-2);display:grid;place-items:center;font-size:12px;font-weight:700}
.guide-block h2{font-size:17px;margin-bottom:12px}
.guide-block p:not(.fine-print){font-size:14px;color:var(--z-text-2);line-height:1.9}
.guide-stack{display:grid;grid-template-columns:1fr 1fr;gap:10px}
.guide-stack>div{padding:14px 16px;border-radius:12px;background:var(--z-surface);border:1px solid var(--z-line)}
.guide-stack span{display:block;font-size:12px;color:var(--z-text-3)}.guide-stack strong{display:block;font-size:16px;margin-top:2px}
.guide-tools{margin-top:10px}.guide-tools b{margin-right:10px;color:var(--z-text)}
.guide-steps{margin:0;padding-left:20px;display:grid;gap:8px;font-size:14px;color:var(--z-text-2);line-height:1.85}
.guide-copy-heading{display:flex;justify-content:space-between;align-items:center;gap:12px;margin-bottom:10px}
.guide-copy-heading h2{margin:0}
.prompt-box{padding:14px 16px;border-radius:12px;background:var(--z-surface-2);font-size:13.5px!important;line-height:1.9;white-space:pre-wrap;color:var(--z-text)!important}
.guide-materials{position:sticky;top:84px;display:grid;gap:12px;padding:22px;border-radius:18px;background:var(--z-surface);border:1px solid var(--z-line)}
.guide-materials h2{font-size:18px}
.guide-materials .muted{font-size:13px}

/* ---------- Forms (publish, profile, feedback) ---------- */
.publish-layout{display:grid;grid-template-columns:minmax(0,1fr) 320px;gap:28px;align-items:start}
.paper-panel{padding:26px 28px;border-radius:18px;background:var(--z-surface);border:1px solid var(--z-line)}
.form-section-title{display:flex;align-items:baseline;gap:10px;margin:8px 0 16px}
.form-section-title>span{width:26px;height:26px;border-radius:50%;background:var(--z-surface-2);display:inline-grid;place-items:center;font-size:12px;font-weight:700;color:var(--z-text-2);flex-shrink:0;align-self:center}
.form-section-title h2{font-size:18px}
.form-section-title small{margin-left:auto;font-size:12px;color:var(--z-text-3)}
.field-label{display:flex;justify-content:space-between;gap:10px;font-size:13px;font-weight:600;color:var(--z-text);margin:16px 0 8px}
.field-label>span:not(.field-name){font-size:12px;font-weight:400;color:var(--z-text-3)}
.field-name{display:inline-flex;gap:4px}
.paper-panel input:not([type=checkbox]):not([type=radio]):not([type=file]),.paper-panel textarea,.paper-panel select,dialog input:not([type=radio]):not([type=checkbox]),dialog textarea,.z-input{width:100%;min-height:44px;border:1px solid var(--z-line);border-radius:12px;background:var(--z-bg);padding:10px 14px;font-size:14px;color:var(--z-text);outline:0;transition:border-color .2s,background .2s}
.paper-panel textarea,dialog textarea,textarea.z-input{line-height:1.8;resize:vertical}
.paper-panel input:focus,.paper-panel textarea:focus,dialog input:focus,dialog textarea:focus,.z-input:focus{border-color:var(--z-line-2);background:var(--z-surface)}
input[type=file]{font-size:12px;color:var(--z-text-2);max-width:100%}
input[type=file]::file-selector-button{border:1px solid var(--z-line-2);border-radius:14px;background:var(--z-chip);color:var(--z-text);padding:5px 12px;margin-right:10px;cursor:pointer}
.artifact-fields{border:0;padding:0;margin:0;min-width:0}
.artifact-fields legend{padding:0;width:100%}
.file-zone{margin-top:12px;padding:16px;border-radius:12px;border:1px dashed var(--z-line-2);display:grid;gap:8px}
.file-zone label{display:grid;gap:2px;cursor:pointer}
.file-zone strong{font-size:14px}.file-zone label span{font-size:12px;color:var(--z-text-3)}
.form-pair{display:grid;grid-template-columns:1fr 1fr;gap:16px}
.optional-panel{margin-top:16px;border-radius:12px;background:var(--z-bg);padding:4px 14px 14px}
.optional-panel summary{cursor:pointer;padding:10px 0 2px;font-size:13px;font-weight:600}
.optional-panel summary span{font-weight:400;color:var(--z-text-3);font-size:12px;margin-left:6px}
.guide-authoring,.submit-authoring{margin-top:26px;padding-top:22px;border-top:1px solid var(--z-line)}
.check-label{display:flex;align-items:flex-start;gap:10px;margin:16px 0 4px;cursor:pointer;font-size:14px;font-weight:600}
.check-label input{width:18px;height:18px;margin:2px 0 0;accent-color:var(--z-pill);flex-shrink:0}
.check-label small{display:block;font-size:12px;font-weight:400;color:var(--z-text-3);margin-top:2px}
.form-actions{display:flex;align-items:center;gap:20px;margin-top:22px}
.storage-notice{margin-top:12px}
.publish-aside{position:sticky;top:84px;display:grid;gap:14px;padding:24px;border-radius:18px;background:var(--z-surface-2)}
.publish-aside h2{font-size:18px}
.publish-aside>div{padding-top:12px;border-top:1px solid var(--z-line)}
.publish-aside>div span{display:block;font-size:14px;font-weight:700}
.publish-aside>div p{font-size:13px;color:var(--z-text-2);margin-top:2px}
.guide-summary-helper{margin:12px 0 6px;padding:16px;border-radius:14px;background:var(--z-bg);display:grid;gap:8px}
.summary-helper-heading{display:flex;justify-content:space-between;align-items:center;gap:12px;flex-wrap:wrap}
.summary-helper-heading h3{font-size:15px;margin-top:2px}
.guide-summary-helper>p{font-size:13px;color:var(--z-text-2)}
.summary-prompt-details summary{cursor:pointer;font-size:13px;font-weight:600}
.summary-prompt-details pre{white-space:pre-wrap;font:12px/1.8 "Microsoft YaHei",system-ui,sans-serif;color:var(--z-text-2);background:var(--z-surface);padding:12px;border-radius:10px;max-height:240px;overflow:auto}
.guide-import-actions{display:flex;justify-content:space-between;align-items:center;gap:12px;font-size:12px;color:var(--z-text-3)}
.preview-steps{padding-left:20px;font-size:14px;color:var(--z-text-2)}

/* Refined select (selects.js) */
.refined-select{position:relative}
.select-trigger{width:100%;min-height:44px;display:flex;align-items:center;justify-content:space-between;gap:10px;padding:0 14px;border:1px solid var(--z-line);border-radius:12px;background:var(--z-bg);font-size:14px;color:var(--z-text);text-align:left}
.select-trigger:hover{border-color:var(--z-line-2)}
.select-chevron{width:8px;height:8px;border-right:1.6px solid var(--z-text-2);border-bottom:1.6px solid var(--z-text-2);transform:rotate(45deg) translateY(-2px);transition:transform .2s;flex-shrink:0}
.is-open .select-chevron{transform:rotate(-135deg) translateY(-1px)}
.select-options{position:absolute;left:0;right:0;top:calc(100% + 6px);z-index:40;max-height:var(--select-room,320px);overflow:auto;padding:6px;border-radius:14px;background:var(--z-surface);border:1px solid var(--z-line);box-shadow:var(--z-shadow-lift);animation:z-pop .16s var(--z-ease)}
.opens-up>.select-options{top:auto;bottom:calc(100% + 6px)}
.select-option{width:100%;display:flex;justify-content:space-between;align-items:center;gap:12px;padding:9px 10px;border-radius:9px;text-align:left}
.select-option strong{display:block;font-size:14px;font-weight:500}
.select-option small{display:block;font-size:11px;color:var(--z-text-3);margin-top:1px}
.select-option.is-active{background:var(--z-surface-2)}
.select-check{opacity:0;font-size:12px;color:var(--z-text)}
.select-option[aria-selected=true] .select-check{opacity:1}
.select-option[aria-selected=true] strong{font-weight:700}
@keyframes z-pop{from{opacity:0;transform:translateY(-4px)}}

/* ---------- Profile ---------- */
.creator-header{margin:26px 0 8px;padding:26px 28px;border-radius:20px;background:var(--z-surface);border:1px solid var(--z-line);display:grid;gap:16px}
.creator-label{display:flex;align-items:center;gap:12px;font-size:12px;color:var(--z-text-3)}
.profile-avatar{width:48px;height:48px;border-radius:50%;background:var(--z-pill);color:var(--z-pill-text);display:grid;place-items:center;font-size:18px;font-weight:700}
.creator-heading{display:flex;justify-content:space-between;align-items:flex-end;gap:20px;flex-wrap:wrap}
.creator-heading h1{font-size:30px;letter-spacing:-.5px}
.creator-heading p{font-size:14px;color:var(--z-text-2);margin-top:4px}
.creator-heading>div:last-child{display:flex;align-items:center;gap:14px}
.creator-counts{display:flex;flex-wrap:wrap;gap:8px 24px;padding-top:14px;border-top:1px solid var(--z-line);font-size:13px;color:var(--z-text-2)}
.creator-counts strong{font-size:20px;color:var(--z-text);margin-right:4px}
.representative-section{margin-top:34px}
.profile-toolbar{display:flex;justify-content:space-between;align-items:center;gap:12px;flex-wrap:wrap;margin:36px 0 18px}
.profile-toolbar h2{font-size:20px}
.trash-row{margin-top:20px;font-size:13px;color:var(--z-text-2)}
.trash-row summary{cursor:pointer}
.trash-item{display:flex;justify-content:space-between;align-items:center;gap:12px;padding:10px 0;border-top:1px solid var(--z-line)}
.trash-item button{font-weight:600;color:var(--z-text)}

/* ---------- Dialogs, toast, assistant ---------- */
dialog{width:min(620px,calc(100vw - 32px));max-height:calc(100dvh - 48px);overflow:auto;border:1px solid var(--z-line);border-radius:20px;padding:22px 26px 26px;background:var(--z-surface);color:var(--z-text);box-shadow:0 30px 80px rgba(0,0,0,.3)}
dialog::backdrop{background:rgba(10,14,12,.5);backdrop-filter:blur(3px)}
dialog[open]{animation:z-pop .22s var(--z-ease)}
.dialog-top{display:flex;justify-content:space-between;align-items:center;gap:12px;margin-bottom:14px}
.icon-button{width:34px;height:34px;border-radius:50%;display:grid;place-items:center;font-size:20px;color:var(--z-text-2)}
.icon-button:hover{background:var(--z-surface-2);color:var(--z-text)}
dialog h2{font-size:22px;margin-bottom:8px}
#detail-content{display:grid;gap:12px}
#profile-form,#feedback-form{display:grid}
#profile-form .button,#feedback-form .button{margin-top:16px;justify-self:start}
.field-label+input,.field-label+textarea{margin-bottom:2px}
.feedback-intro{font-size:13px;margin-bottom:6px}
.feedback-categories{border:0;padding:0;margin:8px 0 0}
.feedback-categories legend{font-size:13px;font-weight:600;margin-bottom:8px}
.feedback-categories>div{display:flex;flex-wrap:wrap;gap:8px}
.feedback-categories label{cursor:pointer}
.feedback-categories input{position:absolute;opacity:0}
.feedback-categories span{display:inline-flex;align-items:center;height:34px;padding:0 15px;border-radius:17px;border:1px solid var(--z-line);font-size:13px;color:var(--z-text-2)}
.feedback-categories input:checked+span{background:var(--z-pill);color:var(--z-pill-text);border-color:transparent;font-weight:600}
.feedback-categories input:focus-visible+span{outline:2px solid var(--z-focus);outline-offset:2px}
.feedback-context{font-size:12px;color:var(--z-text-3);margin-top:8px}
.feedback-actions{display:flex;justify-content:space-between;align-items:center;gap:12px}
#feedback-history{margin-top:16px;font-size:13px}
#feedback-history summary{cursor:pointer;font-weight:600}
#feedback-records article{padding:10px 0;border-top:1px solid var(--z-line)}
#feedback-records p{color:var(--z-text-2)}#feedback-records small{color:var(--z-text-3)}
#toast{position:fixed;left:50%;bottom:28px;z-index:80;transform:translate(-50%,20px);opacity:0;pointer-events:none;max-width:min(520px,calc(100vw - 32px));padding:12px 18px;border-radius:14px;background:var(--z-pill);color:var(--z-pill-text);font-size:13px;box-shadow:var(--z-shadow-lift);transition:.3s var(--z-ease)}
#toast.visible{opacity:1;transform:translate(-50%,0)}
.companion-launcher{position:fixed;right:24px;bottom:24px;z-index:25;display:flex;align-items:center;gap:10px;height:52px;padding:0 20px 0 16px;border-radius:26px;background:var(--z-pill);color:var(--z-pill-text);box-shadow:var(--z-shadow-lift);transition:transform .2s}
.companion-launcher:hover{transform:translateY(-2px)}
.companion-launcher>span:first-child{font-size:18px}
.companion-launcher>span:last-child{display:grid;text-align:left;font-size:14px;font-weight:700;line-height:1.3}
.companion-launcher small{font-size:11px;font-weight:400;opacity:.7}
.assistant-dialog{width:min(680px,calc(100vw - 32px))}
.assistant-hello{display:flex;gap:14px;align-items:flex-start;margin-bottom:14px}
.assistant-hello>span{font-size:22px;color:var(--z-accent)}
.assistant-hello p{font-size:13px;margin-top:2px}
.assistant-input{display:flex;gap:8px}
.assistant-input input{flex:1}
.suggestion-chips{display:flex;flex-wrap:wrap;gap:8px;margin:12px 0}
.suggestion-chips button{height:32px;padding:0 13px;border-radius:16px;border:1px solid var(--z-line);font-size:12.5px;color:var(--z-text-2)}
.suggestion-chips button:hover{color:var(--z-text);border-color:var(--z-line-2)}
.assistant-empty{font-size:13px;color:var(--z-text-3);padding:10px 0}
.assistant-answer{display:flex;gap:10px;padding:12px 14px;border-radius:12px;background:var(--z-surface-2);font-size:13.5px;margin-bottom:10px}
.assistant-answer>span{color:var(--z-accent)}
.assistant-result-list{display:grid;gap:6px}
.assistant-result-list a{display:flex;justify-content:space-between;align-items:center;gap:12px;padding:10px 12px;border-radius:12px;border:1px solid var(--z-line)}
.assistant-result-list a:hover{border-color:var(--z-line-2)}
.assistant-result-list strong{display:block;font-size:14px}.assistant-result-list small{display:block;font-size:12px;color:var(--z-text-3)}
.assistant-no-result{font-size:13px;color:var(--z-text-2);display:grid;gap:6px}

/* ---------- Motion ---------- */
#view.entry-motion{animation:z-enter .45s var(--z-ease)}
@keyframes z-enter{from{opacity:0;transform:translateY(6px)}}
.motion-off *,.motion-off *::before,.motion-off *::after{animation:none!important;transition:none!important}
@media (prefers-reduced-motion:reduce){*,*::before,*::after{animation:none!important;transition:none!important}html{scroll-behavior:auto}}

/* ---------- Responsive ---------- */
@media (max-width:1180px){
  .z-brand{width:170px}.z-zone{display:none}.z-quiet{display:none}
  .work-detail-layout,.guide-layout,.publish-layout{grid-template-columns:1fr}
  .work-detail-aside,.guide-materials,.publish-aside{position:static}
  :root:not([data-mode=dark]) .z-feature video,:root:not([data-mode=dark]) .z-feature>img{width:58%}
  :root:not([data-mode=dark]) .z-feature-copy{max-width:38%}
}
@media (max-width:900px){
  .z-menu{display:inline-grid}
  .z-nav{display:none;position:absolute;top:64px;left:0;right:0;flex-direction:column;align-items:stretch;gap:2px;margin:0;padding:10px clamp(16px,3vw,40px) 16px;background:var(--z-surface);border-bottom:1px solid var(--z-line);box-shadow:var(--z-shadow-lift)}
  .z-nav.is-open{display:flex}
  .z-nav a{height:44px;border-radius:12px;font-size:15px}
  .z-nav .z-nav-extra{display:flex}
  .z-feature{height:auto;display:flex;flex-direction:column-reverse;border-radius:18px}
  .z-feature::after{display:none!important}
  .z-feature video,.z-feature>img{position:relative!important;inset:auto!important;width:100%!important;height:auto!important;aspect-ratio:16/9;border-radius:16px!important}
  .z-feature-copy{position:relative!important;inset:auto!important;transform:none!important;max-width:none!important;padding:18px 4px 4px}
  .z-feature{background:none!important;overflow:visible!important}
}
@media (max-width:650px){
  .gf-row{flex-wrap:nowrap;overflow-x:auto;scrollbar-width:none;margin-right:-16px;padding-right:16px}
  .gf-row::-webkit-scrollbar{display:none}
  .gf-lens{flex-direction:column;align-items:stretch;gap:8px}
  .gf-seg{display:flex}
  .gf-seg button{flex:1 1 auto;padding:0 8px;font-size:12.5px}
  .gf-select{flex:1 1 calc(50% - 4px);min-width:0}
  .t-preview-cta{position:static;padding:12px}
  .t-frame{height:560px}
  .z-top{gap:10px;height:58px}.z-brand{width:150px}
  .z-nav{top:58px}
  .z-actions{gap:6px}
  .z-actions .z-pill{display:none}
  .workspace-bar{flex-wrap:wrap}
  .page-heading{margin:20px 0 22px}
  .z-section-head h2,.z-gallery-head h1{font-size:25px}
  .gallery-searchbar{flex-wrap:wrap}.gallery-search{flex-basis:100%}
  .works-grid{gap:20px 14px}
  .paper-panel{padding:20px 16px}
  .form-pair{grid-template-columns:1fr;gap:0}
  .guide-stack{grid-template-columns:1fr}
  .creator-header{padding:20px}
  .creator-heading h1{font-size:24px}
  .companion-launcher{right:14px;bottom:14px;height:46px;padding:0 16px 0 13px}
  .companion-launcher small{display:none}
  dialog{padding:18px 18px 22px}
}
/* 键盘焦点：输入框关掉了默认外框，这里补一个看得清的 */
.gallery-search input:focus-visible,.comments-section textarea:focus-visible,.paper-panel input:not([type=checkbox]):not([type=radio]):not([type=file]):focus-visible,.paper-panel textarea:focus-visible,.paper-panel select:focus-visible,dialog input:not([type=radio]):not([type=checkbox]):focus-visible,dialog textarea:focus-visible,.z-input:focus-visible{outline:2px solid var(--z-focus);outline-offset:1px;border-color:var(--z-focus)}

/* 返回导航首页：桌面显示图标+文字，窄屏只留图标；手机菜单第一项也能回导航 */
.z-home{display:inline-flex;align-items:center;gap:6px;height:36px;padding:0 12px 0 10px;border-radius:18px;border:1px solid var(--z-line-2);font-size:13px;font-weight:600;color:var(--z-text);white-space:nowrap;transition:background .2s}
.z-home:hover{background:var(--z-surface-2)}
.z-home svg{width:17px;height:17px;fill:none;stroke:currentColor;stroke-width:1.6;stroke-linejoin:round}
.z-nav .z-nav-home{color:var(--z-accent);font-weight:700;border-bottom:1px solid var(--z-line);border-radius:12px 12px 0 0!important;margin-bottom:4px}
@media (max-width:650px){.z-home{width:36px;padding:0;justify-content:center}.z-home span{display:none}}
