:root{--ink:#273338;--teal:#165d56;--soft:#edf4f0;--line:#d4e0da;--muted:#637371}*{box-sizing:border-box}body{margin:0;color:var(--ink);font:16px/1.55 system-ui,-apple-system,Segoe UI,sans-serif;background:#fbfcfa}a{color:var(--teal)}.shell{max-width:1180px;margin:auto;padding:0 22px}.site-header{background:#fff;border-bottom:1px solid var(--line);position:sticky;top:0}.top{display:flex;align-items:center;justify-content:space-between;gap:20px;min-height:74px}.brand{font-size:1.5rem;font-weight:800;color:var(--teal);text-decoration:none}.tools{display:flex;gap:12px;align-items:center;flex-wrap:wrap}.tools a{text-decoration:none}.tools .lang{font-size:.8rem;color:var(--muted)}.tools .on{color:var(--teal);font-weight:800;border-bottom:2px solid var(--teal)}.tools form{padding:0;border:0;margin:0}.layout{display:grid;grid-template-columns:235px minmax(0,1fr);gap:35px;margin-top:32px;min-height:75vh}.sidebar{display:grid;gap:5px}.sidebar a{padding:10px 13px;text-decoration:none;border-radius:8px}.sidebar .active,.sidebar a:hover{background:var(--soft);font-weight:700}main{min-width:0}h1{font-size:2rem;line-height:1.2;margin-top:8px}h2{font-size:1.35rem}.block{border-radius:12px;padding:25px;background:#fff;border:1px solid var(--line);margin:15px 0 25px}.panel{padding:20px;border:1px solid var(--line);background:#fff;border-radius:10px;margin:12px 0}.panel .panel{padding:0;border:0}label{display:block;font-weight:600;margin:12px 0}input,select,textarea{display:block;font:inherit;border:1px solid #bccbc6;border-radius:7px;padding:10px;width:100%;margin-top:4px;background:#fff}textarea{resize:vertical}button{font:inherit;color:#fff;background:var(--teal);padding:9px 17px;border:0;border-radius:7px;cursor:pointer}button:hover{filter:brightness(.9)}button.danger{background:#8e3333}button.quiet{color:var(--teal);background:transparent}.post{padding:16px 0;border-bottom:1px solid var(--line)}.post h3{margin:5px 0}.post p{white-space:normal;overflow-wrap:anywhere}.post small,.chatline small{color:var(--muted)}.chatline{background:var(--soft);padding:12px;margin:10px 0;border-radius:9px;overflow-wrap:anywhere}.chatline p{margin:3px 0}.alert,.success{border-radius:9px;padding:12px;margin-bottom:16px}.alert{background:#fde8e7}.success{background:#e4f3e6}.tabs{display:flex;flex-wrap:wrap;gap:15px;padding-bottom:13px;border-bottom:1px solid var(--line)}.tabs .active{font-weight:800}footer{margin-top:50px;padding-bottom:30px;color:var(--muted);font-size:.9rem}@media(max-width:760px){.layout{grid-template-columns:1fr;gap:15px}.sidebar{display:flex;overflow:auto;gap:6px}.sidebar a{white-space:nowrap}.top{align-items:flex-start;flex-direction:column;padding:15px 22px}.block{padding:16px}}
/* Individual encrypted conversations */
#private-chat .private-toolbar{display:flex;gap:12px;align-items:end;flex-wrap:wrap}
#private-chat .private-toolbar label{flex:1;min-width:180px}
#private-chat .private-toolbar button{margin-bottom:12px}
#private-messages{height:330px;overflow:auto;border:1px solid var(--line);border-radius:8px;background:#f8fbfa;padding:12px}
#private-messages .chatline{max-width:85%}
#private-messages .private-own{margin-left:auto;background:#e0f1e9}
#private-fingerprint{overflow-wrap:anywhere;font-family:monospace;font-size:.82rem}

/* Categorised member listings */
.ad-filters{display:grid;grid-template-columns:repeat(auto-fit,minmax(165px,1fr));align-items:end;gap:10px}.ad-filters label{margin:0}.ad-filters button{margin-bottom:1px}.ad-listing h3{margin:.5rem 0}.ad-images{display:flex;gap:12px;flex-wrap:wrap}.ad-images img{width:160px;height:135px;object-fit:cover;border-radius:9px;border:1px solid var(--line)}.ad-listing details{margin:10px 0}.ad-listing summary{cursor:pointer;color:var(--teal)}

.ad-filters input[type=checkbox]{display:inline-block;width:auto;margin-right:5px}

/* Dedicated, responsive document libraries: daily news, board notices, minutes. */
.section-documents {margin:18px 0 36px}
.section-description {color:var(--muted);margin-bottom:22px}
.section-documents-toolbar {display:flex;justify-content:flex-end;margin-bottom:14px}
.section-add-button {font-weight:700}
.section-documents-list {background:#fff;border:1px solid var(--line);border-radius:12px;overflow:hidden}
.section-document-row {display:flex;align-items:center;gap:16px;padding:18px 20px;border-bottom:1px solid var(--line)}
.section-document-row:last-child{border-bottom:0}
.section-document-icon {width:58px;min-width:58px;height:61px;border-radius:9px;display:flex;align-items:center;justify-content:center;background:#e8f1ed;color:var(--teal);font-size:.78rem;font-weight:850;letter-spacing:.035em}
.section-type-pdf {background:#fbe9e9;color:#a33333}
.section-type-doc,.section-type-docx {background:#eaf0fb;color:#254d91}
.section-type-jpg,.section-type-jpeg {background:#fff0d8;color:#966016}
.section-document-details {min-width:0;flex:1}
.section-document-details h3 {font-size:1.05rem;margin:0 0 4px;overflow-wrap:anywhere}
.section-document-details p {font-size:.87rem;color:var(--muted);margin:0}
.section-document-download {white-space:nowrap;text-decoration:none;font-weight:700;background:var(--soft);padding:9px 15px;border-radius:8px}
.section-document-download:hover {background:#d5e8de}
.section-documents-empty {padding:28px;border:1px dashed var(--line);border-radius:12px;text-align:center;color:var(--muted)}
.section-upload-dialog {width:min(520px,calc(100% - 32px));max-height:calc(100vh - 32px);overflow:auto;padding:25px;border:1px solid var(--line);border-radius:16px;box-shadow:0 18px 65px #0003;color:var(--ink)}
.section-upload-dialog::backdrop {background:#152d34a8}
.section-dialog-head,.section-dialog-actions {display:flex;align-items:center;justify-content:space-between;gap:14px}
.section-dialog-head h2 {margin:0}
.section-dialog-close {font-size:1.7rem;line-height:1}
.section-upload-form input[type=file]{padding:10px;max-width:100%}
.section-upload-hint {font-size:.88rem;color:var(--muted)}
.section-dialog-actions {justify-content:flex-end;margin-top:22px}
@media(max-width:620px){.section-document-row{flex-wrap:wrap;padding:15px 12px;gap:10px}.section-document-icon{width:46px;min-width:46px;height:48px}.section-document-download{margin-left:56px}}

/* Authenticated inline reading: previews stay within the site. */
.section-document-actions{display:flex;gap:9px;flex-wrap:wrap;align-items:center}
.section-document-view{font-weight:700;padding:9px 15px}
.section-preview-dialog{width:min(1100px,calc(100% - 22px));max-width:1100px;height:min(90vh,900px);max-height:90vh;overflow:hidden;padding:14px;border:1px solid var(--line);border-radius:14px;box-shadow:0 18px 65px #0005}
.section-preview-dialog::backdrop{background:#14282bc9}
.section-preview-heading{display:flex;align-items:center;justify-content:space-between;gap:14px}
.section-preview-heading h2{font-size:1.2rem;margin:0 0 8px;overflow-wrap:anywhere}
.section-preview-heading button{font-size:1.8rem;line-height:1}
.section-preview-dialog iframe{width:100%;height:calc(100% - 90px);border:1px solid var(--line);border-radius:8px;background:#fff}
.section-preview-fallback{margin:5px 0;color:var(--muted);font-size:.86rem}
@media(max-width:620px){.section-document-actions{width:100%;margin-left:56px}.section-document-download{margin-left:0}.section-preview-dialog{height:94vh;max-height:94vh;padding:9px}}

/* Member profile photo and directory pictures. */
.profile-photo-card{display:flex;gap:20px;flex-wrap:wrap;align-items:center;background:#fff;border:1px solid var(--line);padding:22px;border-radius:12px;margin:18px 0}
.profile-photo-preview{height:138px;width:138px;flex:0 0 138px;display:grid;place-items:center;border-radius:50%;background:var(--soft);overflow:hidden;color:var(--teal);font-size:4rem;font-weight:700}
.profile-photo-preview img{height:100%;width:100%;object-fit:cover}
.profile-photo-controls{flex:1;min-width:230px}.profile-photo-controls p{margin:0 0 10px}.profile-photo-form{padding:0;border:0;margin:0}.profile-photo-form input{max-width:420px}
.member-directory-item{display:flex;align-items:center;gap:13px;border-bottom:1px solid var(--line);padding:9px 0}.member-directory-item p{margin:0}.member-avatar{height:52px;width:52px;object-fit:cover;border-radius:50%}

/* Interactive cropper: squared preview, pointer drag and accessible zoom. */
.profile-crop-dialog{width:min(580px,calc(100% - 24px));max-height:94vh;overflow-y:auto;border:1px solid var(--line);border-radius:16px;padding:24px;color:var(--ink);box-shadow:0 20px 60px #0004}
.profile-crop-dialog::backdrop{background:#15282dcc}
.profile-crop-dialog h2{margin-top:0}
.profile-crop-dialog p{line-height:1.4}
.profile-crop-canvas-holder{width:min(100%,350px);margin:14px auto;overflow:hidden;border-radius:50%;border:3px solid var(--teal);background:#e3ece9;aspect-ratio:1}
#profile-crop-canvas{display:block;width:100%;height:100%;touch-action:none;cursor:grab;user-select:none}
#profile-crop-canvas:active{cursor:grabbing}
#profile-crop-zoom{width:100%;accent-color:var(--teal);cursor:pointer}
.profile-crop-actions{display:flex;justify-content:flex-end;align-items:center;gap:12px;margin-top:18px}
.profile-crop-dialog [hidden]{display:none}
