.desk { background:#22151e; color:#f9e8dd; }
.desk-header { min-height:67px; display:flex; align-items:center; gap:15px; padding:7px max(19px,calc((100% - 1220px)/2)); border-bottom:1px solid #bc82634d; background:#1b1118; }
.desk-header a:first-child { margin-right:auto; }
.desk-header img { width:80px; height:auto; }
.desk-header a:not(:first-child) { display:inline-flex; min-height:44px; align-items:center; text-decoration:underline; text-underline-offset:.2em; }
.desk main { width:min(calc(100% - 38px),1220px); margin-inline:auto; padding-block:33px 75px; }
.desk h1 { font-size:clamp(3.2rem,7vw,6.6rem); letter-spacing:-.04em; }
.desk h2 { font-size:clamp(2rem,3.8vw,3rem); color:#411e2d; }
.desk button { min-height:43px; padding:7px 12px; background:#3a2331; color:#fff1e5; border:1px solid #c290817a; cursor:pointer; font-size:.87rem; font-weight:690; }
.desk button:hover,.desk button:focus-visible { background:#6b3246; }
.desk button:disabled { opacity:.58; cursor:wait; }
.desk .desk-primary { background:#ae3048; border-color:#c45c64; }
.desk .desk-primary:hover { background:#cb4a5c; }
.desk-login { max-width:490px; margin:clamp(22px,6vw,80px) auto; padding:clamp(22px,4vw,36px); border:1px solid #9a5d657e; background:#2e1b28; }
.desk-login p,.desk-heading p { color:#e7bfb4; margin-top:9px; }
.desk-login form { display:grid; gap:12px; margin-top:20px; }
.desk-heading { display:flex; justify-content:space-between; align-items:end; flex-wrap:wrap; gap:16px; }
.desk-actions { display:flex; flex-wrap:wrap; gap:7px; }
.desk-tabs { display:flex; flex-wrap:wrap; gap:5px; margin-block:23px 10px; }
.desk-tabs [aria-pressed=true] { background:#eacbc0; color:#3e2032; border-color:#eacbc0; }
.desk-grid { display:grid; grid-template-columns:minmax(0,.63fr) minmax(0,1.37fr); gap:12px; align-items:start; }
.desk-index,.desk-edit { color:#37232c; background:#f3e7d8; border:1px solid #bf988d; padding:clamp(13px,3vw,26px); }
.desk-index-top { display:flex; align-items:center; justify-content:space-between; gap:7px; margin-bottom:12px; }
#elementi { display:grid; gap:6px; max-height:63dvh; overflow:auto; }
.desk .desk-record { display:grid; justify-items:start; width:100%; min-width:0; text-align:left; background:#eee0d5; border-color:#88586766; color:#4e273a; padding:9px 10px; overflow-wrap:anywhere; }
.desk .desk-record [class] { max-width:100%; }
.desk-record span { color:#714d5c; font-size:.74rem; }
.desk .desk-record[aria-pressed=true] { background:#5a2a3d; border-color:#5a2a3d; color:#fff0e5; }
.desk .desk-record[aria-pressed=true] span { color:#f5c5b9; }
.desk-empty,#vuoto { color:#745560; margin-top:9px; }
.desk-edit fieldset { display:grid; gap:12px; min-width:0; margin:13px 0 0; border:0; padding:0; }
.desk label { display:grid; gap:5px; color:inherit; font-size:.88rem; font-weight:680; }
.desk :is(input:not([type=checkbox]),textarea) { min-width:0; width:100%; min-height:44px; padding:9px; color:#37232c; background:#fef4eb; border:1px solid #a87e81; font:400 1rem var(--sans); }
.desk-login input { color-scheme:light; }
.desk textarea { resize:vertical; }
.desk :is(input,textarea):focus-visible { outline:2px solid #ac344e; outline-offset:2px; }
.desk-fields { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:9px; }
.desk .desk-check { display:flex; align-items:center; gap:8px; min-height:36px; }
.desk .desk-check input { width:19px; height:19px; accent-color:#a0304a; }
.desk-image { display:grid; grid-template-columns:minmax(0,1fr) minmax(0,.52fr); gap:12px; padding:12px; background:#ead8cb; border:1px solid #a37a7d6a; }
.desk-image p { margin:5px 0 8px; font-size:.81rem; color:#73505f; }
.desk-image img { width:100%; height:130px; object-fit:contain; background:#291a22; }
.desk .upload-button { position:relative; display:inline-flex; align-items:center; min-height:43px; padding:8px 11px; background:#603247; color:#fff1e9; cursor:pointer; }
.desk .upload-button:focus-within { outline:2px solid #ac344e; outline-offset:2px; }
.desk .upload-button input { position:absolute; inset:0; opacity:0; cursor:pointer; }
.desk-image button { margin:4px 0; }
.desk-item-actions { border-top:1px solid #915c6555; padding-top:11px; }
.desk .desk-danger { background:#7b293d; }
.desk-status { margin-top:12px; color:#ffd0ad; font-size:.92rem; }
.desk-status[data-error=true] { color:#ffb1bc; }
@media (max-width:740px) { .desk-grid { grid-template-columns:minmax(0,1fr); } #elementi { max-height:230px; } .desk-fields { grid-template-columns:minmax(0,1fr); } }
@media (prefers-reduced-motion:no-preference) { .desk #redazione:not([hidden]),.desk-edit { animation:desk-in .38s cubic-bezier(.16,1,.3,1) both; } }
@keyframes desk-in { from { opacity:.35; transform:translateY(12px); } to { opacity:1; transform:none; } }


.desk label small { color:#745560; font-weight:500; }
.desk-format { margin-top:6px; }
.desk .desk-format button { min-height:39px; color:#653247; background:#eee0d5; border-color:#9c737e; }
.desk .desk-format button:hover { color:#fff1e5; background:#6b3246; }
.desk-publication,.desk-album { background:#ead8cb; border:1px solid #a37a7d6a; padding:12px; }
.desk-publication { display:flex; flex-wrap:wrap; align-items:center; justify-content:space-between; gap:10px; }
.desk-publication p,.desk-album p { color:#694351; font-size:.82rem; margin-top:3px; }
.desk #apri-pagina { display:inline-flex; align-items:center; min-height:43px; padding:7px 11px; background:#70283f; color:#fff1e9; font-size:.87rem; font-weight:690; }
.desk #apri-pagina:hover { background:#933c56; }
.desk-album h3 { font-size:clamp(1.85rem,3.6vw,2.65rem); }
.desk-album-row { display:grid; grid-template-columns:74px minmax(0,1fr); gap:8px 11px; align-items:center; padding:9px 0; border-top:1px solid #b694886e; }
.desk-album-row img { grid-row:1 / 3; width:74px; height:63px; object-fit:cover; background:#392333; }
.desk-album-actions button { min-height:37px; padding:4px 8px; font-size:.75rem; }
.desk-album-actions button:disabled { cursor:default; }
.desk-preview { width:min(calc(100vw - 24px),850px); max-height:90dvh; background:#f3e7d8; color:#3e2833; border:1px solid #b58172; padding:clamp(14px,3vw,27px); }
.desk-preview::backdrop { background:#170b16d8; }
.desk-preview-bar { display:flex; align-items:center; justify-content:space-between; gap:12px; margin-bottom:16px; }
.desk-preview-bar span,#anteprima-meta { color:#704758; font-size:.85rem; font-weight:650; }
#anteprima-meta { margin-block:8px; }
#anteprima-cover { width:100%; height:auto; max-height:46dvh; object-fit:contain; background:#271820; }
#anteprima-corpo p { margin-block:12px; white-space:pre-wrap; overflow-wrap:anywhere; }
#anteprima-corpo h3 { font-size:clamp(1.9rem,3.9vw,2.8rem); color:#71273f; margin-top:14px; }
.desk-preview-summary { font-weight:690; }
.desk-status:not(:empty) { position:sticky; z-index:2; bottom:8px; background:#3a2331; border:1px solid #b47668; padding:8px 10px; }
@media (max-width:440px) {
  .desk-album-row { grid-template-columns:56px minmax(0,1fr); }
  .desk-album-row img { width:56px; height:51px; }
  .desk-album .desk-index-top { align-items:flex-start; flex-wrap:wrap; }
}


.desk-save-actions { position:sticky; top:0; z-index:3; display:flex; justify-content:flex-end; padding:8px; margin-bottom:10px; background:#271923; border:1px solid #81535d; }
.desk-save-actions .desk-actions { justify-content:flex-end; }
.desk-edit :is(input,textarea,button) { scroll-margin-block:72px 43px; }
@media (max-width:440px) {
  .desk-save-actions { justify-content:stretch; }
  .desk-save-actions .desk-actions { flex:1; display:grid; grid-template-columns:minmax(0,.8fr) minmax(0,1.2fr); }
}