.media-library { --ml-ink:#253c31; --ml-green:#1b4c3d; --ml-muted:#627860; --ml-line:#dbe3d3; font-size:14px; color:var(--ml-ink); background:#fffefa; border:1px solid var(--ml-line); border-radius:15px; padding:30px; margin-bottom:28px; }
.media-library *, .media-library-dialog * { box-sizing:border-box; }
.media-library svg, .media-library-dialog svg { width:21px; height:21px; flex-shrink:0; }
.ml-heading { display:flex; align-items:flex-start; justify-content:space-between; gap:20px; margin-bottom:27px; }
.ml-kicker { display:block; font-size:10px; letter-spacing:1.5px; font-weight:650; color:#5f7955; line-height:1.6; }
.ml-heading h2 { font-family:Georgia,"Times New Roman",serif; font-size:32px; font-weight:400; letter-spacing:-.9px; line-height:1.2; margin:11px 0; }
.ml-heading p { font-size:14px; color:var(--ml-muted); line-height:1.65; }
.ml-saved-count { display:inline-block; font-size:12px; color:#637d56; padding:7px 10px; background:#edf3e4; border-radius:6px; white-space:nowrap; margin-top:7px; }
.ml-upload-layout { display:grid; grid-template-columns:1.2fr 1fr; gap:28px; align-items:center; }
.ml-dropzone { display:flex; flex-direction:column; align-items:center; justify-content:center; border:1px dashed #aabd97; border-radius:12px; background:#f4f7ee; text-align:center; padding:29px 22px; min-height:259px; transition:background .15s ease, border-color .15s ease; }
.ml-dropzone.is-dragging { border:2px solid #397044; background:#e8f1df; }
.ml-upload-icon { display:grid; place-items:center; height:47px; width:47px; border-radius:10px; background:#e3edda; color:#57774a; margin-bottom:17px; }
.ml-upload-icon svg { width:24px; height:24px; }
.ml-dropzone h3 { font-size:20px; font-family:Georgia,"Times New Roman",serif; font-weight:400; letter-spacing:-.3px; line-height:1.3; margin-bottom:10px; }
.ml-dropzone p { color:#6e825f; font-size:13px; line-height:1.65; max-width:270px; margin-bottom:16px; }
.ml-dropzone small { margin-top:12px; font-size:12px; color:#788969; }
.ml-button { display:inline-flex; align-items:center; justify-content:center; min-height:44px; padding:10px 15px; border:1px solid transparent; border-radius:7px; background:transparent; color:#365c3b; font:inherit; font-size:13px; font-weight:600; line-height:1.35; cursor:pointer; }
.ml-primary { background:#1b4c3d; color:#fffefa; border-color:#1b4c3d; }
.ml-primary:hover { background:#2c614d; }
.ml-secondary { border-color:#cad8bf; background:#fffefa; }
.ml-secondary:hover { background:#edf3e4; }
.ml-text { background:transparent; color:#6d7e60; }
.ml-text:hover { text-decoration:underline; text-underline-offset:4px; }
.ml-button:disabled { opacity:.55; cursor:default; }
.media-library button:focus-visible, .media-library input:focus-visible, .media-library textarea:focus-visible, .media-library summary:focus-visible, .media-library-dialog button:focus-visible, .media-library-dialog input:focus-visible, .media-library-dialog textarea:focus-visible { outline:3px solid #427c62; outline-offset:3px; }
.ml-upload-guide { padding:15px 12px; }
.ml-upload-guide h3 { font-family:Georgia,"Times New Roman",serif; font-weight:400; font-size:26px; line-height:1.25; letter-spacing:-.6px; margin:13px 0; max-width:290px; }
.ml-upload-guide p { color:#6c805f; font-size:14px; line-height:1.75; margin-top:13px; max-width:340px; }
.ml-upload-guide p:last-child { font-size:12px; }
.ml-error, .ml-dialog-error { border:1px solid #e5c3b3; border-radius:8px; background:#fbefe7; color:#8a4837; padding:14px 16px; font-size:13px; line-height:1.6; margin-top:19px; }
#media-photo-staging { margin:26px 0; padding:25px; border:1px solid #cfdfc2; border-radius:12px; background:#f6f9ee; }
.ml-preview { display:flex; align-items:center; gap:22px; margin-bottom:24px; }
.ml-preview img { display:block; width:150px; height:112px; object-fit:cover; border-radius:9px; flex-shrink:0; }
.ml-preview > div { min-width:0; flex:1; }
.ml-preview h3 { font-size:16px; font-weight:600; line-height:1.5; margin:7px 0; overflow-wrap:anywhere; }
.ml-preview p { color:#74886a; font-size:12px; line-height:1.6; margin-bottom:10px; }
.ml-preview .ml-button { font-size:12px; }
.ml-form-grid { display:grid; grid-template-columns:1fr 1fr; gap:20px; }
.ml-full { grid-column:1/-1; }
.ml-field { min-width:0; }
.ml-field label { display:block; font-size:13px; font-weight:600; color:#47633e; margin-bottom:8px; }
.ml-field input, .ml-field textarea { display:block; font:inherit; font-size:14px; width:100%; min-width:0; padding:12px; min-height:45px; border:1px solid #cbd9c0; border-radius:7px; background:#fffefa; color:#2b4b31; }
.ml-field textarea { line-height:1.65; resize:vertical; }
.ml-rights { display:flex; align-items:flex-start; gap:11px; padding-top:20px; color:#436538; font-size:13px; line-height:1.6; cursor:pointer; }
.ml-rights input { margin-top:3px; width:18px; height:18px; flex-shrink:0; accent-color:#2b6444; }
.ml-rights-note { font-size:12px; color:#73886a; padding-left:29px; margin-top:7px; line-height:1.7; }
.ml-upload-footer { display:flex; align-items:center; justify-content:flex-end; gap:15px; border-top:1px solid #dce6d0; margin-top:23px; padding-top:19px; }
.ml-upload-footer > span { font-size:13px; color:#527749; }
.ml-library-heading { display:flex; align-items:center; justify-content:space-between; gap:15px; margin:30px 0 18px; border-top:1px solid var(--ml-line); padding-top:26px; }
.ml-library-heading h3 { font-family:Georgia,"Times New Roman",serif; font-size:25px; font-weight:400; letter-spacing:-.5px; }
.ml-library-heading > span { font-size:12px; color:#7a8b6d; }
.ml-gallery { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:20px; }
.ml-asset { border:1px solid var(--ml-line); background:#fffefa; border-radius:10px; overflow:hidden; min-width:0; }
.ml-asset-image { width:100%; height:170px; background:#edf3e3; display:grid; place-items:center; color:#92a580; }
.ml-asset-image img { width:100%; height:100%; object-fit:cover; display:block; }
.ml-asset-copy { padding:17px; }
.ml-asset-kicker { display:block; font-size:9px; color:#809170; letter-spacing:1.4px; font-weight:600; margin-bottom:8px; }
.ml-asset-copy h3 { font-size:15px; line-height:1.45; font-weight:600; overflow-wrap:anywhere; }
.ml-asset-copy > p { font-size:12px; line-height:1.7; color:#718766; margin-top:10px; overflow-wrap:anywhere; }
.ml-asset-meta { display:flex; flex-wrap:wrap; gap:8px 15px; color:#7b8c6e; font-size:12px; margin-top:12px; }
.ml-asset-footer { display:flex; align-items:center; justify-content:space-between; flex-wrap:wrap; gap:10px; border-top:1px solid #e2e9d9; margin-top:15px; padding-top:11px; }
.ml-asset-footer > span { display:flex; align-items:center; gap:6px; font-size:11px; color:#658357; }
.ml-asset-footer > span svg { width:15px; height:15px; }
.ml-asset-footer .ml-button { font-size:12px; padding:10px 12px; }
.ml-asset-provenance { border-top:1px solid #e5ecdc; margin-top:13px; padding-top:10px; }
.ml-asset-provenance summary { font-size:12px; color:#708563; cursor:pointer; min-height:30px; padding:5px 0; }
.ml-asset-provenance p { font-size:12px; color:#7d8e6d; line-height:1.7; margin:8px 0; overflow-wrap:anywhere; }
.ml-asset-provenance strong { font-weight:550; color:#5c7550; }
.ml-fingerprint { font-family:ui-monospace,SFMono-Regular,Menlo,monospace; }
.ml-no-photos { display:flex; gap:18px; align-items:center; padding:27px 24px; background:#f4f7ed; border:1px solid #e1e8d6; border-radius:10px; }
.ml-no-photos > span { display:grid; place-items:center; color:#91a582; background:#e7efde; width:47px; height:47px; border-radius:9px; flex-shrink:0; }
.ml-no-photos h3 { font-size:16px; font-weight:550; line-height:1.5; }
.ml-no-photos p { font-size:13px; line-height:1.7; color:#768969; margin-top:6px; }
.ml-references { margin-top:25px; border-top:1px solid var(--ml-line); padding-top:20px; }
.ml-references > summary { font-size:13px; color:#627d55; font-weight:550; cursor:pointer; min-height:44px; padding:9px 0; }
.ml-references > p { font-size:13px; line-height:1.75; color:#7a8c6c; margin:5px 0 19px; max-width:700px; }
.ml-sr-only { position:absolute!important; width:1px!important; height:1px!important; padding:0!important; margin:-1px!important; overflow:hidden!important; clip:rect(0,0,0,0)!important; white-space:nowrap!important; border:0!important; }
.media-library-dialog { border:1px solid #d2dfc7; background:#fffefa; color:#253c31; border-radius:14px; padding:0; width:640px; max-width:calc(100vw - 30px); max-height:calc(100dvh - 35px); overflow-y:auto; box-shadow:0 25px 80px #19362835; font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif; font-size:14px; line-height:1.5; }
.media-library-dialog::backdrop { background:#1b302960; backdrop-filter:blur(4px); }
.ml-dialog-heading { display:flex; align-items:flex-start; justify-content:space-between; gap:20px; padding:27px; border-bottom:1px solid #e0e7d6; }
.ml-dialog-heading h2 { font-family:Georgia,"Times New Roman",serif; font-size:30px; font-weight:400; letter-spacing:-.7px; line-height:1.25; margin:11px 0; }
.ml-dialog-heading p { font-size:13px; color:#738766; line-height:1.6; overflow-wrap:anywhere; }
.ml-close { display:grid; place-items:center; width:44px; height:44px; border:0; background:#edf3e3; color:#658356; border-radius:8px; cursor:pointer; flex-shrink:0; }
.ml-dialog-body { padding:27px; }
.ml-dialog-footer { display:flex; justify-content:flex-end; align-items:center; gap:11px; padding:20px 27px; border-top:1px solid #e0e7d6; background:#f6f9ee; }
@media(max-width:1100px) { .ml-gallery { grid-template-columns:repeat(2,minmax(0,1fr)); } .ml-upload-layout { gap:20px; } }
@media(max-width:760px) { .media-library { padding:25px; } .ml-upload-layout { grid-template-columns:1fr; } .ml-upload-guide { padding:4px; } .ml-upload-guide h3, .ml-upload-guide p { max-width:none; } .ml-heading { flex-direction:column; gap:12px; } .ml-saved-count { margin-top:0; } }
@media(max-width:480px) {
  .media-library { padding:22px 18px; }
  .ml-heading h2 { font-size:31px; }
  .ml-heading p { font-size:13px; }
  .ml-upload-layout { gap:23px; }
  .ml-upload-guide h3 { font-size:25px; }
  .ml-upload-guide p { font-size:13px; }
  .ml-dropzone { padding:26px 18px; }
  .ml-gallery { grid-template-columns:minmax(0,1fr); gap:19px; }
  .ml-asset-image { height:190px; }
  #media-photo-staging { padding:18px; }
  .ml-preview { align-items:flex-start; flex-direction:column; gap:17px; }
  .ml-preview img { width:100%; height:160px; }
  .ml-form-grid { grid-template-columns:1fr; gap:20px; }
  .ml-preview .ml-kicker { font-size:9px; }
  .ml-rights-note { padding-left:0; margin-top:12px; }
  .ml-upload-footer { flex-direction:column; align-items:stretch; }
  .ml-library-heading { align-items:flex-start; flex-direction:column; gap:8px; }
  .ml-no-photos { padding:23px 18px; align-items:flex-start; gap:13px; }
  .ml-no-photos h3 { font-size:15px; }
  .ml-no-photos p { font-size:12px; }
  .media-library-dialog { max-width:calc(100vw - 22px); max-height:calc(100dvh - 24px); }
  .ml-dialog-heading, .ml-dialog-body { padding:23px 20px; }
  .ml-dialog-heading h2 { font-size:27px; }
  .ml-dialog-footer { padding:18px 20px; }
}
@media(prefers-reduced-motion:reduce) { .media-library * { transition:none!important; } }
