/* Keep every caption and control aligned, including native date inputs. */
#editor{width:580px;max-width:calc(100% - 24px);max-height:calc(100dvh - 32px);padding:26px;box-sizing:border-box}
#editor .modal-head{gap:16px;margin-bottom:24px;align-items:flex-start}
#editor .modal-head h2{margin:8px 0 0;line-height:1.4}
#editor .modal-head .close{flex:none;width:36px;height:36px;padding:0;line-height:1;font-size:26px}
#editor .form-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:18px 14px;align-items:start}
#editor #play-fields{display:contents}
#editor [hidden]{display:none!important}
#editor .form-grid>label,#editor #play-fields>label{min-width:0;gap:8px;font-size:12px;line-height:18px}
#editor .form-grid label>span{display:block;line-height:18px}
#editor .form-grid input:not([type=checkbox]):not([type=hidden]),#editor .form-grid select,#editor .form-grid textarea{min-width:0;width:100%;box-sizing:border-box;font:inherit;font-size:14px;padding:11px 12px;border-radius:7px}
#editor .form-grid input:not([type=checkbox]):not([type=file]):not([type=hidden]),#editor .form-grid select{height:44px}
#editor input[type=date]{appearance:none;-webkit-appearance:none;display:block}
#editor .form-grid textarea{min-height:104px;resize:vertical;line-height:1.6}
#editor .rating-field{min-width:0;font-size:12px;line-height:18px}
#editor .field-hint{margin:4px 0 0;color:#8b977e;font-size:11px;line-height:1.7}
#editor .photo-field{padding:14px;min-width:0}
#editor .photo-field label{line-height:18px}
#editor .photo-field>input{padding:0!important;font-size:12px!important;line-height:1.7}
#editor .form-help{line-height:1.7;margin:18px 0}
#editor .modal-actions{display:flex;justify-content:flex-end;gap:10px;padding-top:16px;margin-top:0}
#editor .modal-actions button{min-height:44px;margin:0}
.star-picker{gap:0;flex-wrap:wrap;row-gap:5px}
.star-cell{position:relative;display:inline-block;flex:none;width:32px;height:40px;font-size:30px;line-height:40px;color:#bcc7ae;user-select:none}
.star-empty,.star-fill{position:absolute;inset:0;pointer-events:none;line-height:inherit;font-size:inherit;text-align:center}
.star-fill{color:#aa9048;clip-path:inset(0 calc(100% - var(--fill)) 0 0)}
.star-picker button.star-hit{position:absolute;top:0;bottom:0;width:50%;padding:0;border:0;border-radius:3px;background:transparent;font-size:inherit;touch-action:manipulation}
.star-hit.left{left:0}.star-hit.right{right:0}
.star-picker button.star-hit:hover{background:#a8996417}
.star-hit:focus-visible{outline:2px solid #214f43;outline-offset:1px}
.rating-value{margin-left:9px;font-size:11px;color:#758468;white-space:nowrap}
.star-picker button.clear-star{width:28px;height:40px;margin-left:2px;font-size:20px}
#editor .star-picker{margin:6px 0 0}
#editor .star-cell{width:42px;height:44px;font-size:36px;line-height:44px}
#editor .rating-value{font-size:12px}
@media(max-width:480px){
  #editor{padding:20px;max-height:calc(100dvh - 24px)}
  #editor .form-grid{gap:16px 12px}
  #editor .form-grid input:not([type=checkbox]):not([type=hidden]),#editor .form-grid select,#editor .form-grid textarea{font-size:16px;padding:10px}
  #editor .modal-head h2{font-size:22px}
  #editor .star-cell{width:38px}
}

#editor .theme-search{margin-top:-10px;border:1px solid #d7e0cf;border-radius:7px;overflow:hidden;background:#fff;min-width:0}
#theme-search-results{max-height:240px;overflow:auto}#theme-search-results [role=option]{padding:12px;cursor:pointer;border-bottom:1px solid #edf0e7}
#theme-search-results [role=option]:hover,#theme-search-results [aria-selected=true]{background:#edf3e6}
#theme-search-results strong{display:block;font-size:14px;font-weight:600;overflow-wrap:anywhere}#theme-search-results span{display:block;margin-top:5px;color:#7c8b70;font-size:11px;overflow-wrap:anywhere}
#theme-search-status{margin:0;padding:10px 12px;font-size:11px;line-height:1.6;color:#7c8b70;background:#f7f9f2}
