.library-surface .page{padding-top:30px;max-width:1800px}.library-page{padding:12px 8px 30px}.library-heading{display:flex;align-items:center;justify-content:space-between;gap:25px;margin-bottom:42px}.library-heading h1{font-size:32px;font-weight:600;letter-spacing:-1px;margin:12px 0 14px;line-height:1.2}.library-heading p{font-size:12px;color:#91988b;margin:0}.library-heading .eyebrow{font-size:9px;letter-spacing:2px}.library-heading-actions{display:flex;gap:10px;align-items:center}.library-button,.library-primary{display:inline-flex;align-items:center;justify-content:center;gap:8px;padding:11px 15px;border:1px solid #e2e5dc;border-radius:10px;background:#ffffffa8;color:#65735a;font-family:inherit;font-weight:500;line-height:1.4;font-size:11px;cursor:pointer;white-space:nowrap;text-decoration:none}.library-button .ui-icon,.library-primary .ui-icon{width:15px;height:15px}.library-button:hover{background:#e9ede2;border-color:#ced8c2}.library-primary{background:#33442c;border-color:#33442c;color:#fff}.library-primary:hover{background:#526b43;color:#fff}.library-button:disabled,.library-primary:disabled{opacity:.45;cursor:default}.library-toolbar{display:flex;align-items:center;justify-content:space-between;gap:20px;margin-bottom:26px;padding-bottom:18px;border-bottom:1px solid #e4e7dd}.library-tabs{display:flex;gap:8px;flex-wrap:wrap}.library-tabs button{border:0;background:transparent;padding:10px 17px;border-radius:9px;color:#98a08f;font-size:12px;cursor:pointer}.library-tabs button.active{color:#4d6141;background:#e7ecdf;font-weight:600}.library-tabs button:hover{color:#4d6141}.library-tools{display:flex;gap:20px;align-items:center}.library-count{font-size:10px;color:#a0a795;white-space:nowrap}.library-search{display:flex;align-items:center;gap:8px;padding:7px 12px;border:1px solid #e1e6d8;background:#fff8;border-radius:10px;width:250px}.library-search .ui-icon{width:15px;height:15px;color:#9ca78e}.frontend-surface .library-search input{width:100%;border:0;background:transparent;padding:4px 0;box-shadow:none;font-size:11px;outline:none;color:#57674a}.library-search input::placeholder{color:#a2aa99}.library-feedback{min-height:0;color:#7e8b6e;font-size:12px;line-height:1.6}.library-feedback:not(:empty){padding:12px 15px;margin-bottom:22px;background:#edf1e7;border-radius:10px}.library-feedback.error{background:#fbebe7;color:#a5503e}.library-grid{columns:4;column-gap:18px}.library-card{break-inside:avoid;display:inline-block;width:100%;margin-bottom:22px;border:1px solid #e4e7dd;border-radius:15px;background:#fff;overflow:hidden;box-shadow:0 6px 22px #34452804}.library-card-media{position:relative;width:100%;padding:0;background:#e7eadf;min-height:160px;display:block;border:0;text-align:left;cursor:pointer;overflow:hidden}.library-card-media img,.library-card-media video{display:block;width:100%;min-height:160px;max-height:520px;object-fit:cover;transition:transform .35s}.library-card:hover .library-card-media img{transform:scale(1.025)}.library-card-media video{aspect-ratio:16/10;object-fit:contain;background:#e0e5d8}.library-card-failed{min-height:230px;padding:32px 24px;display:flex;flex-direction:column;justify-content:center;align-items:center;gap:16px;background:linear-gradient(140deg,#edf1e6,#e5e9dc);color:#758565}.library-card-failed>span{font-size:12px;line-height:1.7;text-align:center}.library-card-failed strong{font-size:15px;font-weight:500}.library-card-badge{position:absolute;left:11px;top:11px;background:#fffffff0;border:1px solid #e7eadf;backdrop-filter:blur(8px);padding:5px 8px;border-radius:6px;font-size:9px;color:#586b47}.library-card-zoom{position:absolute;right:13px;bottom:13px;border:1px solid #ffffff6a;border-radius:50%;width:32px;height:32px;background:#ffffffe0;display:grid;place-items:center;color:#495b3c;opacity:0;transition:opacity .2s}.library-card:hover .library-card-zoom,.library-card:focus-within .library-card-zoom{opacity:1}.library-card-body{padding:14px}.library-card-meta{display:flex;justify-content:space-between;align-items:center;gap:10px;color:#99a08f;font-size:9px}.library-card-meta strong{font-size:11px;font-weight:500;color:#546149;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.library-card-prompt{margin:10px 0 12px;font-size:11px;line-height:1.75;color:#8f9885;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;overflow-wrap:anywhere}.library-card-actions{display:flex;gap:6px;flex-wrap:wrap}.library-card-actions button,.library-card-actions a{display:inline-flex;align-items:center;justify-content:center;border:0;border-radius:7px;font-size:9px;background:#f0f3eb;color:#6e825b;padding:8px 9px;cursor:pointer;text-decoration:none}.library-card-actions button:disabled{color:#b7bdae;background:#f6f7f3;cursor:default}.library-card-actions .danger{margin-left:auto;color:#a5aa9b;background:transparent}.library-card-actions .danger:hover{background:#fbebe5;color:#b35840}.library-more{display:flex;justify-content:center;padding-top:20px}.library-empty{text-align:center;padding:85px 20px 100px;border:1px dashed #dce3d2;border-radius:20px;background:#f8f9f3}.library-empty-mark{display:grid;place-items:center;border:1px solid #dee6d5;background:#eaf0e2;border-radius:20px;width:66px;height:66px;margin:0 auto 26px;color:#82976c}.library-empty-mark .ui-icon{width:29px;height:29px}.library-empty h2{font-size:20px;font-weight:500;color:#5e704f;margin:0 0 13px}.library-empty p{font-size:12px;color:#96a18a;line-height:1.8;margin-bottom:25px}.work-dialog{position:fixed;inset:0;width:min(1160px,calc(100vw - 70px));height:min(790px,calc(100dvh - 90px));max-width:none;max-height:none;padding:0;background:#fafbf6;border:1px solid #fff7;border-radius:22px;overflow:hidden;color:#45543a;box-shadow:0 30px 110px #0004}.work-dialog[open]{display:grid;grid-template-columns:minmax(0,1fr) 335px}.work-dialog::backdrop,.history-confirm::backdrop{background:#1a2314a6;backdrop-filter:blur(8px)}.work-dialog-close{position:absolute;right:13px;top:13px;z-index:2;border:0;width:31px;height:31px;border-radius:50%;background:#e6ebde;color:#657951;font-size:23px;line-height:1;cursor:pointer}.work-dialog-media{min-width:0;min-height:0;display:flex;align-items:center;justify-content:center;background:#e9eddf;padding:25px;overflow:hidden}.work-dialog-media img,.work-dialog-media video{max-width:100%;max-height:100%;width:auto;height:auto;object-fit:contain;border-radius:6px}.work-dialog-info{display:flex;flex-direction:column;overflow:auto;padding:32px 25px 20px;border-left:1px solid #e0e6d5;min-width:0}.work-dialog-author{display:flex;gap:11px;align-items:center;margin-bottom:36px;padding-right:18px}.work-dialog-author>div{min-width:0}.work-dialog-author strong{font-size:12px;display:block;font-weight:600;overflow-wrap:anywhere}.work-dialog-author time{display:block;font-size:9px;color:#9ca78e;margin-top:6px}.work-dialog-prompt .eyebrow{font-size:8px;color:#99a589}.work-dialog-prompt p{font-size:12px;line-height:1.9;white-space:pre-wrap;overflow-wrap:anywhere;max-height:220px;overflow:auto;color:#778568;margin:12px 0 26px}.work-dialog-specs{display:grid;grid-template-columns:1fr 1fr;gap:18px 12px;margin:0 0 24px}.work-dialog-specs div{min-width:0}.work-dialog-specs dt{font-size:9px;color:#a2ab97;margin-bottom:6px}.work-dialog-specs dd{font-size:11px;color:#667a53;margin:0;overflow-wrap:anywhere}.work-dialog-actions{display:flex;flex-direction:column;gap:8px;margin-top:auto}.work-dialog-notice{padding:12px;background:#edf1e5;border-radius:8px;color:#8b9a7a;font-size:10px;line-height:1.7;margin-bottom:15px}.work-dialog-pager{display:flex;align-items:center;justify-content:space-between;gap:7px;border-top:1px solid #e5e9dc;margin-top:20px;padding-top:16px}.work-dialog-pager button{padding:7px;background:transparent;border:0;font-size:10px}.work-dialog-pager span{font-size:9px;color:#a0ad91}.history-list{display:grid;gap:15px}.history-card{display:grid;grid-template-columns:125px minmax(0,1fr) auto;gap:25px;align-items:center;padding:20px;border:1px solid #e1e6d8;border-radius:17px;background:#fff}.history-preview{height:96px;border-radius:10px;background:#edf1e5;overflow:hidden;display:flex;align-items:center;justify-content:center;color:#889b74;font-size:32px;position:relative}.history-preview img,.history-preview video{width:100%;height:100%;object-fit:cover}.history-preview.canvas-preview{background-color:#f2f5ec;background-image:radial-gradient(#c9d4bd 1px,transparent 1px);background-size:12px 12px}.canvas-preview span{background:#fff;border:1px solid #cbd7bd;box-shadow:5px 5px 0 #e3ead9;border-radius:8px;padding:11px;font-size:23px}.history-info{min-width:0}.history-info h2{font-size:14px;font-weight:550;line-height:1.65;margin:0 0 11px;color:#596e48;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;overflow-wrap:anywhere}.history-info p{font-size:10px;color:#9ba78e;display:flex;gap:10px;flex-wrap:wrap;margin:0}.history-type-pill{font-size:9px;color:#7a9165;padding:3px 6px;border-radius:5px;background:#eff4e7}.history-actions{display:flex;gap:8px;align-items:center}.history-actions button{font-size:10px}.history-actions .history-delete{color:#a1aa97;border:0;background:transparent}.history-confirm{border:1px solid #e0e7d6;border-radius:20px;box-shadow:0 30px 90px #0003;max-width:430px;width:calc(100vw - 36px);padding:32px;color:#506342;background:#fafbf6}.history-confirm h2{font-size:22px;font-weight:550;margin:15px 0}.history-confirm p{font-size:12px;line-height:1.9;color:#849574;margin-bottom:25px}.history-confirm label{display:flex;flex-direction:column;gap:10px;font-size:11px;color:#8a987c}.frontend-surface .history-confirm input{border:1px solid #d9e2ce;border-radius:9px;background:#fff;padding:12px;font-size:12px}.history-confirm-actions{display:flex;gap:10px;justify-content:flex-end;margin-top:24px}.upload-label{position:relative}.library-card [data-load-error]{padding:30px 15px;min-height:200px;color:#9ca78e;font-size:11px;line-height:1.8}
@media(min-width:1600px){.library-grid{columns:5}}@media(max-width:1200px){.library-grid{columns:3}.history-card{grid-template-columns:100px minmax(0,1fr);gap:18px}.history-actions{grid-column:2;justify-content:flex-end}.history-preview{grid-row:span 2;align-self:stretch;height:auto;min-height:115px}.library-heading{margin-bottom:30px}.library-heading h1{font-size:28px}.library-heading-actions{gap:7px}.work-dialog[open]{grid-template-columns:minmax(0,1fr) 300px}.work-dialog{width:calc(100vw - 40px)}}@media(max-width:900px){.library-grid{columns:2}.library-toolbar{flex-wrap:wrap}.library-tools{margin-left:auto}.work-dialog[open]{grid-template-columns:minmax(0,1fr) 270px}.work-dialog-info{padding:30px 20px 16px}.library-heading{align-items:flex-start}.library-heading-actions{flex-wrap:wrap;justify-content:flex-end}.library-heading p{line-height:1.8}.library-search{width:220px}}
@media(max-width:640px){.library-surface .page{padding-top:15px}.library-page{padding:10px 0 25px}.library-heading{display:block;margin-bottom:25px}.library-heading h1{font-size:28px;margin-top:10px}.library-heading p{font-size:11px}.library-heading-actions{justify-content:flex-start;margin-top:23px}.library-heading .eyebrow{font-size:8px}.library-toolbar{gap:14px;margin-bottom:18px;padding-bottom:16px}.library-tabs{gap:1px;width:100%}.library-tabs button{font-size:11px;padding:9px 12px}.library-tools{width:100%;justify-content:space-between;gap:8px}.library-search{flex:1;width:auto;max-width:280px}.library-search input{font-size:11px!important}.library-count{font-size:9px}.library-grid{column-gap:10px}.library-card{border-radius:11px;margin-bottom:12px}.library-card-body{padding:11px}.library-card-media{min-height:110px}.library-card-media img{min-height:110px;max-height:330px}.library-card-meta{display:block}.library-card-meta>span{display:block;margin-top:5px;font-size:8px}.library-card-prompt{font-size:10px;margin:8px 0 10px;line-height:1.8}.library-card-actions{gap:4px}.library-card-actions button,.library-card-actions a{font-size:9px;padding:7px 6px}.library-card-badge{font-size:8px;padding:4px 6px;top:8px;left:8px}.library-card-zoom{display:none}.library-card-failed{padding:25px 12px;min-height:185px}.library-card-failed strong{font-size:13px}.library-card-failed>span{font-size:10px}.library-button,.library-primary{font-size:10px;padding:10px 12px}.library-empty{padding:65px 20px}.library-empty h2{font-size:17px}.library-empty p{font-size:11px}.work-dialog{width:calc(100vw - 20px);height:calc(100dvh - 40px);border-radius:17px;overflow:auto}.work-dialog[open]{display:flex;flex-direction:column}.work-dialog-media{height:43dvh;min-height:230px;padding:17px;flex-shrink:0}.work-dialog-info{overflow:visible;border-left:0;border-top:1px solid #e2e8d8;padding:22px 20px}.work-dialog-author{margin-bottom:25px}.work-dialog-prompt p{max-height:160px;font-size:12px}.work-dialog-specs{grid-template-columns:repeat(3,1fr);gap:15px 10px}.work-dialog-actions{display:grid;grid-template-columns:1fr 1fr}.work-dialog-actions>a:first-child{grid-column:span 2}.work-dialog-close{position:fixed;right:23px;top:31px;box-shadow:0 3px 15px #0002}.work-dialog-pager{margin-top:19px}.history-card{padding:14px;grid-template-columns:74px minmax(0,1fr);gap:13px;border-radius:13px}.history-preview{min-height:102px;border-radius:8px}.history-info h2{font-size:12px;margin-bottom:8px}.history-info p{font-size:9px;gap:6px}.history-actions{gap:3px;flex-wrap:wrap}.history-actions button{padding:7px 8px;font-size:9px}.history-confirm{padding:29px 24px}.history-confirm .work-dialog-close{position:absolute;top:10px;right:10px}.history-confirm h2{font-size:20px}}
.history-text-preview{font-family:inherit;font-size:10px;line-height:1.7;padding:12px;color:#8a9b79;overflow:hidden;max-height:100%;overflow-wrap:anywhere}.history-text-dialog{width:min(760px,calc(100vw - 35px));max-width:760px;max-height:85dvh;overflow:auto}.history-text-dialog pre{font-family:inherit;font-size:13px;line-height:1.9;white-space:pre-wrap;overflow-wrap:anywhere;background:#eef3e6;padding:22px;border-radius:12px;max-height:50dvh;overflow:auto;color:#667e51}.history-text-dialog>.library-button{margin-right:10px}
