:root{font-family:system-ui,-apple-system,"PingFang SC",sans-serif;color:#243c4b;background:#f7f9f8}*{box-sizing:border-box}body{margin:0}button,input,select,a{font:inherit}button,.primary{border:1px solid #cdd9d2;border-radius:9px;padding:10px 15px;background:white;color:inherit;cursor:pointer;text-decoration:none}button:hover{background:#eaf4ef}.primary,#loginForm button{background:#27835d;color:white;border-color:#27835d}a{color:inherit}.topbar{display:flex;align-items:center;gap:22px;padding:20px 5vw;border-bottom:1px solid #dce4df;background:white}.topbar a{text-decoration:none;font-weight:700}.topbar button{margin-left:auto}main{max-width:1100px;margin:40px auto;padding:0 24px}h1{margin:0 0 24px;font-size:32px}h2{font-size:21px}.heading,.filters,.actions{display:flex;gap:12px;align-items:center}.heading{justify-content:space-between}.eyebrow{font-size:11px;letter-spacing:2px;color:#678578}.filters{margin:22px 0}#breadcrumbs{flex:1;display:flex;flex-wrap:wrap;gap:5px}#breadcrumbs button{border:0;background:none;padding:5px}select,input{padding:10px;border:1px solid #cdd9d2;border-radius:7px;min-width:0;background:white;color:inherit}.row{display:flex;align-items:center;gap:16px;padding:20px 16px;background:white;border:1px solid #dce4df;border-bottom:0}.row:first-child{border-radius:12px 12px 0 0}.row:last-child{border-bottom:1px solid #dce4df;border-radius:0 0 12px 12px}.row .summary{flex:1;min-width:0}.row .title{font-weight:650;text-decoration:none;overflow-wrap:anywhere}.row button.title{border:0;padding:0}.meta{color:#718277;font-size:12px;margin:7px 0 0}.row .actions{gap:5px}.row .actions button{font-size:12px;padding:7px}.danger{color:#ad3636}#gate{max-width:400px;margin:100px auto}#loginForm{display:grid;gap:12px}#empty{padding:70px 20px;text-align:center;color:#78867e}#status,#loginError{color:#ac3a36}dialog{border:1px solid #d1ddd6;border-radius:14px;padding:24px;width:min(440px,90vw);color:inherit}dialog::backdrop{background:#172b2444}dialog form{display:grid;gap:12px}dialog .actions{justify-content:flex-end;margin-top:15px}label[hidden],[hidden]{display:none!important}#warning{white-space:pre-line;color:#8b4740}@media(max-width:620px){main{margin:24px auto;padding:0 12px}.heading{align-items:flex-start;flex-direction:column}.row{flex-wrap:wrap;padding:15px 12px}.row .actions{width:100%;flex-wrap:wrap}.filters{flex-wrap:wrap}#breadcrumbs{flex-basis:100%}h1{font-size:27px}}

.article-row{flex-wrap:nowrap}.article-more{position:relative;flex-shrink:0}.article-more>summary{list-style:none;cursor:pointer;padding:4px 10px;border-radius:6px;font-size:22px;line-height:1}.article-more>summary::-webkit-details-marker{display:none}.article-more>summary:hover,.article-more[open]>summary{background:#eaf4ef}.article-more>summary:focus-visible{outline:2px solid #27835d;outline-offset:2px}.article-row .article-more .actions{position:absolute;right:0;top:100%;z-index:10;display:flex;flex-direction:column;align-items:stretch;gap:4px;width:130px;padding:8px;background:white;border:1px solid #dce4df;border-radius:9px;box-shadow:0 5px 18px #243c4b20}.article-more:not([open])>.actions{display:none}

.category-tabs{display:flex;align-items:stretch;gap:4px;overflow-x:auto;background:#edf0ed;border-bottom:1px solid #d2ddd5;padding:8px 8px 0;margin-top:20px}
.category-tab{display:flex;align-items:center;flex-shrink:0;max-width:260px;border-radius:13px 13px 0 0;border:1px solid transparent;border-bottom:0}
.category-tab.selected{background:white;border-color:#d2ddd5}
.category-tab [role=tab]{border:0;background:transparent;border-radius:13px 0 0 0;padding:13px 16px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;min-width:70px}
.category-tab.selected [role=tab]{color:#246345;font-weight:600}
.category-tab .category-close{background:transparent;border:0;padding:6px 10px;margin-right:5px;font-size:21px;border-radius:7px;line-height:1}
.category-close:hover{background:#e0e7e2}.category-tabs .category-add{background:transparent;border:0;font-size:29px;padding:4px 15px;flex-shrink:0}
.category-tabs button:focus-visible{outline:2px solid #27835d;outline-offset:-3px}

/* Teaching journal: quiet green palette, compact controls and readable categories. */
.diary-list-page{background:#f5f8f6;color:#263e46}
.diary-list-page .topbar{height:72px;padding:0 max(28px,calc((100vw - 1120px)/2));gap:18px;background:#ffffffb3;border-color:#e3eae5;font-size:14px}
.diary-list-page .topbar>a{font-size:16px;letter-spacing:.02em}
.diary-list-page .brand-divider{color:#c1ccc5;font-weight:300}
.diary-list-page #logout{width:36px;height:36px;color:#71867a;background:transparent;border-color:transparent}
.diary-list-page #logout:hover{background:#e9f0eb;color:#315f49}
.diary-list-page main{max-width:1120px;margin:24px auto 72px;padding:0 28px}
.diary-list-page .heading{margin-bottom:16px;gap:20px}
.diary-list-page .eyebrow{font-size:10px;font-weight:650;letter-spacing:.19em;margin:0 0 6px;color:#779386}
.diary-list-page h1{font-size:30px;line-height:1.3;letter-spacing:.02em;margin:0;font-weight:680}
.diary-list-page .page-description{margin:6px 0 0;font-size:13px;line-height:1.6;color:#819087}
.diary-list-page #create{width:46px;height:46px;padding:0;border-radius:14px;background:#27835d;border-color:#27835d;box-shadow:0 4px 10px #27835d12}
.diary-list-page #create:hover{background:#216f50}
.diary-list-page #create .ui-icon{width:22px;height:22px}
.diary-list-page .journal-toolbar{display:flex;align-items:center;gap:22px;padding:0 0 12px;border-bottom:1px solid #e0e8e2}
.diary-list-page .category-tabs{flex:1;min-width:0;display:flex;align-items:center;gap:8px;padding:4px 2px;margin:0;border:0;background:transparent;scrollbar-width:thin;scrollbar-color:#ccdad0 transparent}
.diary-list-page .category-tab{height:38px;max-width:260px;border:1px solid transparent;border-radius:11px;background:transparent;transition:background .15s,border-color .15s}
.diary-list-page .category-tab:hover{background:#eaf0ec}
.diary-list-page .category-tab.selected{background:#e1eee6;border-color:#caddcf}
.diary-list-page .category-tab [role=tab]{display:flex;gap:8px;align-items:center;min-width:0;padding:9px 12px;border-radius:10px;color:#728378;font-size:13px;line-height:18px;font-weight:500}
.diary-list-page .category-tab [role=tab]>span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.diary-list-page .category-tab [role=tab] .ui-icon{width:16px;height:16px;color:#8c9e93}
.diary-list-page .category-tab.selected [role=tab]{color:#2b684b;font-weight:650}
.diary-list-page .category-tab.selected [role=tab] .ui-icon{color:#498767}
.diary-list-page .category-tab .category-close{width:26px;height:26px;padding:0;margin-right:6px;border-radius:7px;color:#93a499}
.diary-list-page .category-close .ui-icon{width:13px;height:13px}
.diary-list-page .category-tab .category-close:hover{background:#d3e3d9;color:#466d55}
.diary-list-page .category-tabs .category-add{width:32px;height:32px;margin-left:2px;padding:0;border-radius:50%;border:1px dashed #cbd9cf;color:#799382;background:transparent}
.diary-list-page .category-add .ui-icon{width:17px;height:17px}
.diary-list-page .category-tabs .category-add:hover{background:#e2eee6;border-color:#8eae9a;color:#286a49}
.diary-list-page .filters{flex-shrink:0;gap:8px;margin:0}
.diary-list-page .tag-filter{display:flex;align-items:center;gap:8px;padding:0 10px;height:36px;background:#fff;border:1px solid #e0e7e2;border-radius:10px;color:#8b9b90}
.diary-list-page .tag-filter .ui-icon{width:15px;height:15px}
.diary-list-page #tagFilter{padding:0 16px 0 0;max-width:160px;height:34px;border:0;border-radius:0;font-size:12px;background:transparent;color:#657c6d;cursor:pointer}
.diary-list-page #refresh{width:36px;height:36px;border:1px solid #e0e7e2;border-radius:10px;color:#7b8f80;background:#fff}
.diary-list-page #refresh .ui-icon{width:17px;height:17px}
.diary-list-page .list-caption{display:flex;justify-content:space-between;padding:12px 4px 9px;font-size:11px;letter-spacing:.07em;color:#85978b}
.diary-list-page #articleCount{letter-spacing:0;color:#99a79e}
.diary-list-page #list:not(:empty){background:#fff;border:1px solid #e0e8e2;border-radius:16px;box-shadow:0 4px 20px #294f391f}
.diary-list-page .article-row{gap:16px;padding:22px 24px;border:0;border-bottom:1px solid #edf1ee;border-radius:0;background:transparent;transition:background .15s}
.diary-list-page .article-row:first-child{border-radius:16px 16px 0 0}
.diary-list-page .article-row:last-child{border-bottom:0;border-radius:0 0 16px 16px}
.diary-list-page .article-row:only-child{border-radius:16px}
.diary-list-page .article-row:hover{background:#fbfdfb}
.diary-list-page .article-symbol{display:flex;align-items:center;justify-content:center;flex-shrink:0;width:40px;height:44px;border-radius:11px;background:#f1f6f2;color:#87a18e}
.diary-list-page .article-symbol .ui-icon{width:20px;height:20px}
.diary-list-page .article-row .title{display:inline-block;font-size:15px;line-height:1.6;font-weight:620;color:#304a43;letter-spacing:.01em}
.diary-list-page .article-row .title:hover{color:#27835d}
.diary-list-page .meta{display:flex;align-items:center;gap:7px;flex-wrap:wrap;margin:9px 0 0;line-height:1.4}
.diary-list-page .article-tag{padding:3px 7px;background:#f1f5f2;border-radius:5px;font-size:10px;color:#819487}
.diary-list-page .article-date{display:inline-flex;align-items:center;gap:5px;padding:2px 0;font-size:11px;color:#95a39a}
.diary-list-page .article-date .ui-icon{width:12px;height:12px}
.diary-list-page .article-more>summary{display:flex;align-items:center;justify-content:center;width:32px;height:32px;padding:0;border-radius:9px;color:#91a296}
.diary-list-page .article-more>summary .ui-icon{width:19px;height:19px}
.diary-list-page .article-more .actions{display:grid;grid-template-columns:repeat(3,36px);width:auto;gap:5px;padding:8px;border-radius:12px;border-color:#dce7df;box-shadow:0 8px 24px #2e513b16}
.diary-list-page .article-more .actions .icon-button{width:36px;height:36px;padding:0;background:transparent;border:0;border-radius:8px;color:#6a8271}
.diary-list-page .article-more .actions .icon-button:hover{background:#edf4ef}
.diary-list-page .article-more .actions .danger{color:#b4726c}
.diary-list-page #empty{margin:0;padding:70px 20px;border:1px dashed #d6e2d9;border-radius:16px;background:#ffffff80;font-size:13px;color:#8b9c90}
.diary-list-page dialog{border-radius:18px;border-color:#d9e4dc;padding:26px;box-shadow:0 16px 60px #1a3a2822}
.diary-list-page dialog #confirm{color:#fff;background:#27835d;border-color:#27835d}
@media(max-width:700px){.diary-list-page .topbar{height:60px;padding:0 20px;gap:12px}.diary-list-page main{margin:18px auto;padding:0 18px}.diary-list-page .heading{flex-direction:row;align-items:center;margin-bottom:14px}.diary-list-page h1{font-size:26px}.diary-list-page .journal-toolbar{flex-wrap:wrap;gap:8px;padding-bottom:10px}.diary-list-page .category-tabs{flex-basis:100%;order:2}.diary-list-page .filters{margin-left:auto}.diary-list-page .article-row{padding:18px 14px;gap:12px}.diary-list-page .article-symbol{width:32px;height:38px;border-radius:8px}.diary-list-page .article-row .title{font-size:14px}.diary-list-page .article-tag{font-size:10px}.diary-list-page .article-row .article-more .actions{width:auto}.diary-list-page .list-caption{padding-top:10px}}

.diary-list-page .category-tab.drop-target{background:#d5ebdf;border-color:#27835d;box-shadow:0 0 0 2px #27835d33}
.diary-list-page .article-row[draggable=true]{cursor:grab}
.diary-list-page .article-row.dragging{opacity:.45;cursor:grabbing}
