/* style.css */
*{box-sizing:border-box}body{margin:0;background:#f5f6f8;color:#1d2633;font:14px/1.6 -apple-system,BlinkMacSystemFont,"Segoe UI","PingFang SC",sans-serif}header{background:#fff;border-bottom:1px solid #e4e8ed;padding:18px 4%;display:flex;align-items:center;justify-content:space-between;gap:20px}a{color:#1760aa;text-decoration:none}a:hover{text-decoration:underline}.brand{font-weight:750;font-size:22px;color:#202c40;white-space:nowrap}.brand span{font-size:16px;margin-left:12px;font-weight:500}nav,.actions{display:flex;align-items:center;gap:20px}nav form{margin:0}main{max-width:1440px;margin:32px auto;padding:0 32px;min-height:70vh}.card{background:white;border:1px solid #e3e7ed;border-radius:14px;padding:24px;margin-bottom:20px;box-shadow:0 3px 12px #17273a04}h1{font-size:27px;line-height:1.4;margin:6px 0 20px;letter-spacing:-.5px}h2{font-size:17px;margin:0 0 16px}.eyebrow{font-size:11px;letter-spacing:2px;color:#61758d;font-weight:650}.muted,small{color:#626d7b}.auth{max-width:440px;margin:8vh auto}.auth button{width:100%;margin-top:14px}label{display:block;font-size:13px;font-weight:550;margin-bottom:16px}input,select,textarea{display:block;width:100%;font:inherit;color:#1d2633;border:1px solid #cbd3dd;border-radius:8px;background:#fff;padding:10px 12px;margin-top:6px}input:focus,textarea:focus,select:focus{outline:2px solid #bddcff;border-color:#2b72b8}button,.button{border:0;background:#2168ad;color:#fff;border-radius:8px;padding:10px 18px;cursor:pointer;font:inherit;white-space:nowrap}button:hover,.button:hover{background:#174e84;text-decoration:none}.quiet{color:#485b70;background:#edf1f5}.error{background:#fff1ed;color:#a2371c;border-radius:8px;padding:12px}.heading{display:flex;align-items:center;justify-content:space-between}.search{display:flex;align-items:center;gap:12px;padding:16px}.search input{flex:1;margin:0}.search select{max-width:290px;margin:0}.tablewrap{padding:0;overflow:auto}table{border-collapse:collapse;width:100%;text-align:left}th{font-size:12px;font-weight:600;color:#65758a;background:#f8fafc}th,td{padding:13px 18px;border-bottom:1px solid #edf0f4;vertical-align:top}tr:last-child td{border-bottom:0}td:first-child{min-width:310px}.filename{font-weight:550;color:#263a53}small{display:block;margin-top:4px;font-size:12px;max-width:800px}.tag{font-size:11px;border:1px solid #e0e7ef;border-radius:5px;padding:3px 5px;color:#526781}.pagination{display:flex;justify-content:center;gap:28px;margin:25px}.empty{text-align:center;padding:60px;color:#626d7b}.matches>div{padding:10px 0;border-top:1px solid #edf0f4}.matches a{display:block;font-size:12px}.filetitle{font-size:22px;overflow-wrap:anywhere;margin-top:12px}.preview{width:100%;height:78vh;border:1px solid #dbe2ea;border-radius:12px;background:#fff}.edit{max-width:800px;margin:0 auto}.danger{border-top:1px solid #eee;margin-top:35px;padding-top:20px;color:#924632}.dangerbutton{background:#a43e32}.userform{display:flex;align-items:end;gap:16px;flex-wrap:wrap}.userform label{margin:0;flex:1;min-width:140px}.userform button{margin-bottom:1px}.trashrow{display:flex;align-items:center;justify-content:space-between;padding:14px;border-bottom:1px solid #eee}footer{text-align:center;padding:24px;color:#788595;font-size:12px}@media(max-width:850px){header{align-items:flex-start;flex-direction:column}nav{flex-wrap:wrap;gap:12px}main{padding:0 14px;margin-top:20px}.search{flex-wrap:wrap}.search input{flex-basis:100%}.search select{flex:1}.heading{align-items:start}.actions{gap:12px;flex-wrap:wrap}th,td{padding:12px}.card{border-radius:10px}.auth{margin:4vh auto}}
td.actions{display:table-cell;white-space:nowrap}td.actions a+a{margin-left:16px}

/* header.css */
.library-header{background:#fff;border-bottom:1px solid #e5e9ee;padding:0;display:block;position:relative;z-index:10}.header-inner{box-sizing:border-box;max-width:1500px;margin:auto;padding:24px 28px;display:flex;align-items:center;justify-content:space-between;gap:24px}.library-brand{display:flex;align-items:center;gap:20px;color:#202c40;white-space:nowrap;text-decoration:none}.library-brand:hover{text-decoration:none}.library-brand strong{font-size:34px;font-weight:750;line-height:1.2;letter-spacing:-.7px}.library-brand span{font-size:23px;font-weight:600;line-height:1.3}.header-right,.primary-nav,.header-tools{display:flex;align-items:center;gap:10px}.header-right{gap:24px}.header-tools{gap:8px;border-left:1px solid #e5e9ee;padding-left:22px}.header-right a,.header-right summary,.header-right button{font:13px/1.5 -apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;color:#536273;text-decoration:none}.primary-nav>a{padding:8px 11px;border-radius:7px;white-space:nowrap}.primary-nav>a:hover,.header-menu>summary:hover{background:#f5f7fa}.primary-nav>a.active{color:#255c91;background:#edf3f9}.library-header .header-menu{position:relative;background:transparent;border:0;padding:0;margin:0;border-radius:0;color:#536273}.header-menu>summary{display:flex;align-items:center;gap:8px;cursor:pointer;list-style:none;padding:7px 9px;border-radius:7px;white-space:nowrap;min-height:34px;box-sizing:border-box}.header-menu>summary::-webkit-details-marker{display:none}.header-menu summary svg{width:14px;height:14px;fill:none;stroke:currentColor;stroke-width:1.5;flex-shrink:0}.header-menu summary .globe{width:18px;height:18px}.header-menu[open]>summary{background:#f1f4f8}.header-popover{box-sizing:border-box;position:absolute;right:0;top:calc(100% + 10px);min-width:160px;background:#fff;border:1px solid #e2e7ee;border-radius:12px;box-shadow:0 12px 36px #25354b20;padding:6px;z-index:50}.header-popover>a,.header-popover form>button{display:block;box-sizing:border-box;text-align:left;width:100%;padding:10px 12px;border:0;border-radius:7px;background:transparent;color:#34465c;white-space:nowrap}.header-popover>a:hover,.header-popover button:hover{background:#f1f5fa;text-decoration:none}.header-popover form{margin:0}.header-popover input{display:none}.language-options{width:240px}.language-options>button{display:flex;align-items:center;justify-content:space-between;gap:12px;width:100%;border:0;border-radius:8px;background:transparent;padding:10px 12px;text-align:left;cursor:pointer;white-space:normal}.language-options .localized-language{display:block;font-size:13px;font-weight:550}.language-options small{display:block;font-size:11px;color:#8390a0;margin:2px 0 0}.language-options button[aria-pressed="true"]{background:#edf4fb;color:#285e91}.language-check{font-size:15px;visibility:hidden}.language-options button[aria-pressed="true"] .language-check{visibility:visible}.account-avatar{height:26px;width:26px;border-radius:50%;background:#edf1f6;color:#596b82;display:inline-flex;align-items:center;justify-content:center;font-size:11px;font-weight:600}.header-menu summary:focus-visible,.header-popover button:focus-visible,.header-popover a:focus-visible{outline:2px solid #8aafd7;outline-offset:2px}@media(max-width:850px){.header-inner{padding:18px 14px;gap:15px;flex-wrap:wrap}.library-brand strong{font-size:29px}.library-brand span{font-size:20px}.header-right{gap:10px;flex-wrap:wrap;justify-content:flex-end}.header-tools{padding-left:10px}.primary-nav{gap:3px}.primary-nav>a{padding:7px}.header-menu summary{padding:6px}.header-menu .header-popover{max-width:calc(100vw - 28px)}}@media(max-width:520px){.header-right{width:100%;justify-content:space-between}.header-tools{border-left:0;padding-left:0}.primary-nav{flex-wrap:wrap}.account-menu summary>span:not(.account-avatar){display:none}.language-options{right:-36px}}

.header-popover [hidden]{display:none!important}
.translated-name{overflow-wrap:anywhere}.original-name{display:block;font-size:11px;line-height:1.45;color:#69778a;font-weight:400;margin-top:3px;overflow-wrap:anywhere}.original-name[hidden]{display:none}.filetitle{font-size:20px;line-height:1.5}.sheet-scroll{overflow:auto;max-height:68vh;border:1px solid #dce3eb;border-radius:8px}.sheet-table{border-collapse:separate;border-spacing:0;font-size:13px;width:max-content;min-width:100%}.sheet-table td,.sheet-table th{padding:7px 10px;border-right:1px solid #e3e8ee;border-bottom:1px solid #e3e8ee;max-width:320px;min-width:60px;white-space:pre-wrap;overflow-wrap:anywhere}.sheet-table th{background:#edf2f7;font-weight:500}.sheet-table thead th{position:sticky;top:0;z-index:2}.sheet-table tbody th{position:sticky;left:0;z-index:1}.sheet-table .formula-cell{background:#fff4cd}.sheet-tabs,.sheet-pager{display:flex;flex-wrap:wrap;align-items:center;gap:14px;margin:12px 0}.sheet-tabs a{padding:5px 10px;border-radius:6px}.sheet-tabs [aria-current]{background:#e7f0ff}.preview-note{color:#58667a;font-size:13px}.spreadsheet-card{max-width:100%;overflow:hidden}

/* loading.css */
#page-loading{position:fixed;inset:0;z-index:1000;display:flex;align-items:center;justify-content:center;gap:16px;padding:24px;background:rgba(245,248,252,.48);-webkit-backdrop-filter:blur(7px);backdrop-filter:blur(7px);pointer-events:auto;touch-action:none;color:#3f526b;font:14px/1.5 -apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif}#page-loading[hidden]{display:none}.loading-spinner{display:block;flex-shrink:0;width:48px;height:48px;border-radius:50%;background:conic-gradient(from 0deg,#526b8600,#526b86);-webkit-mask:radial-gradient(farthest-side,transparent calc(100% - 3px),#000 0);mask:radial-gradient(farthest-side,transparent calc(100% - 3px),#000 0);animation:bom-spin 1000ms linear infinite}@keyframes bom-spin{to{transform:rotate(360deg)}}@media(prefers-reduced-motion:reduce){.loading-spinner{animation:none}}

/* Fail open even if a script or network request never completes. */
#page-loading:not([hidden]){animation:bom-loading-release 12s step-end forwards}@keyframes bom-loading-release{0%{visibility:visible}100%{visibility:hidden;pointer-events:none}}

/* preview.css */
.document-page main{max-width:none;margin:12px auto 0;padding:0 20px;min-height:0}.document-toolbar{padding:10px 14px 11px;margin:0 0 10px;background:#fff;border:1px solid #e0e6ed;border-radius:10px}.document-topline{display:flex;align-items:center;justify-content:space-between;gap:12px}.document-context,.document-actions{display:flex;align-items:center;gap:16px;flex-wrap:wrap;font-size:12px;line-height:1.5}.document-type{color:#66758a;white-space:nowrap}.document-note{color:#697586;border-left:1px solid #dfe5ed;padding-left:16px}.document-actions{flex-shrink:0;gap:16px}.document-actions a{white-space:nowrap}.document-actions .button{padding:5px 12px;border-radius:6px;font-size:12px}.document-toolbar .filetitle{font-size:15px;font-weight:600;letter-spacing:0;line-height:1.45;margin:7px 0 0;overflow-wrap:anywhere}.document-toolbar .original-name{font-size:11px;line-height:1.4;margin-top:2px;max-width:none}.document-page .preview{display:block;width:100%;max-width:100%;height:calc(100dvh - 198px);min-height:320px;border-radius:9px}.document-page footer{padding:8px;font-size:11px}.document-page .preview-note{margin:7px 0;font-size:12px}.paired-heading{margin:6px 0;font-size:12px;line-height:1.4;overflow-wrap:anywhere}.paired-heading .original-name{font-size:10px}.document-page .spreadsheet-card{padding:12px 14px;margin-bottom:8px;border-radius:9px}.document-page .sheet-tabs,.document-page .sheet-pager{margin:7px 0;font-size:12px}.document-page .sheet-scroll{max-height:calc(100dvh - 280px)}
@media(max-width:850px){.document-page main{padding:0 12px;margin-top:8px}.document-topline{align-items:flex-start;flex-wrap:wrap;gap:8px}.document-context{gap:10px}.document-note{padding-left:10px}.document-actions{gap:14px}.document-toolbar{padding:9px 11px}.document-toolbar .filetitle{font-size:14px}.document-page .preview{height:65dvh}.document-page .sheet-scroll{max-height:65dvh}}
