/* Isolated resource intake surfaces; the approved main-page geometry stays shared. */
.material-file-picker{padding:18px;border:1px dashed #bac9df;border-radius:10px;background:#f6f8fc}.material-file-picker input{display:block;width:100%;font-size:12px}.material-file-picker input::file-selector-button{border:1px solid #d6deeb;border-radius:7px;padding:8px 12px;margin-right:12px;background:white;color:#325bd1;cursor:pointer}.material-file-picker .small{margin-top:10px}.material-file-summary{display:flex;flex-direction:column;gap:6px;background:#f5f7fb;padding:16px;border:1px solid #e2e7ef;border-radius:10px;margin:16px 0 20px;font-size:12px;overflow-wrap:anywhere}.material-file-summary strong{font-size:13px}.material-file-summary span{color:#7c899c}.material-file-summary a{color:#325bd1}.material-tags{display:flex;flex-wrap:wrap;gap:7px;margin:8px 0}.attribute-tag{display:inline-flex;align-items:center;gap:5px;background:#eef2fe;border:1px solid #dce5fc;color:#42639d;border-radius:6px;font-size:12px;padding:4px 9px;max-width:100%;overflow-wrap:anywhere}.attribute-tag button{padding:0 2px;border:0;background:transparent;color:#8192b1;font-size:16px}.material-tag-entry{display:flex;gap:8px}.material-tag-entry input{flex:1;min-width:0}.material-tag-entry button{flex:none}.material-matches{padding:15px;border:1px solid #e4e8ee;border-radius:10px;background:#fafbfc;margin-top:20px}.material-matches h3{font-size:12px;margin-bottom:10px}#material-matches{display:flex;flex-wrap:wrap;gap:8px}.material-match{display:flex;flex-direction:column;gap:2px;border-radius:7px;background:white;border:1px solid #e5e9f0;padding:7px 10px}.material-match strong{font-size:12px;font-weight:550}.material-match small{font-size:10px;color:#8390a3}.material-file-preview{font-size:12px}.material-file-preview pre{max-height:260px;overflow:auto;white-space:pre-wrap;overflow-wrap:anywhere;padding:14px;background:#f6f8fb;font:12px/1.8 ui-monospace,monospace}
#discovery-dialog{width:min(864px,calc(100vw - 64px));max-width:none;height:min(676px,calc(100vh - 64px));max-height:calc(100vh - 64px);padding:0;overflow:hidden;background:#fff}#discovery-dialog[open]{display:flex;flex-direction:column}.discovery-header{display:flex;align-items:center;gap:12px;padding:22px 26px;border-bottom:1px solid #e4e7ed;flex:none}.discovery-header .panel-back{font-size:30px;width:30px;height:32px;line-height:20px}.discovery-header h2{font-size:19px}.discovery-header .badge{margin-left:auto}#discovery-body{padding:18px 26px 26px;overflow:auto;flex:1;min-height:0}#discovery-dialog .panel{position:static;width:auto;height:auto;padding:20px;border:1px solid #e2e7ef;border-radius:12px;background:white;box-shadow:none;min-width:0}#discovery-dialog .marketplace-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr))}#discovery-dialog .marketplace-detail{display:grid;margin-top:18px}#discovery-dialog .marketplace-cover{display:flex;flex-direction:column;justify-content:space-between;padding:15px;background:#edf2fc}#discovery-dialog .marketplace-cover strong{font-size:16px}#discovery-dialog .marketplace-card>button{align-self:flex-start}#discovery-dialog .section-head{margin:20px 0 15px}#discovery-dialog h3{font-size:14px}.discovery-note{font-size:11px;color:#8591a2}#discovery-status{min-height:36px;padding:10px 26px;background:#f7f9fc;border-top:1px solid #e4e7ed;font-size:11px;color:#52735f;flex:none}
@media(max-width:700px){#discovery-dialog .marketplace-grid,#discovery-dialog .marketplace-detail{grid-template-columns:1fr}}

.material-file-control{position:relative;display:inline-flex;padding:8px 14px;background:#fff;color:#325bd1;border:1px solid #d6deeb;border-radius:7px;font-size:12px}.material-file-control input{position:absolute;inset:0;opacity:0;cursor:pointer}.material-file-control:focus-within{outline:2px solid #a9bdf7;outline-offset:3px}

/* Skill import uses the same form and file-picker language as the other resource intake flows. */
#dialog:has(#skill-source) .skill-import-method>label{margin:0 0 var(--ui-field-content-gap);font-weight:600}
#dialog:has(#skill-source) #skill-source{display:block;width:100%;padding:10px 12px;border:1px solid #c6d2e2;border-radius:8px;background:#fff}
#dialog:has(#skill-source) #skill-source::placeholder{color:#98a2b1}
#dialog:has(#skill-source) .skill-import-method>.helper{margin-top:var(--ui-field-content-gap)}
.skill-import-choice{margin-top:var(--ui-dialog-section-gap)}
.skill-import-choice>p:first-child{margin:0 0 var(--ui-space-2);font-weight:600}
.skill-import-choice .skill-select-all,.skill-import-choice .skill-candidate{display:flex;align-items:center;gap:var(--ui-space-2);min-height:36px;margin:0;padding:var(--ui-space-2) var(--ui-space-3);border-radius:8px;cursor:pointer}
.skill-import-choice .skill-select-all{background:#eef3ff;color:#2f55bd;font-weight:600}
.skill-import-choice input[type=checkbox]{width:16px;height:16px;min-width:16px;margin:0;accent-color:#325bd1}
.skill-candidate-list{max-height:min(240px,38vh);overflow-y:auto;margin-top:var(--ui-space-2);padding:var(--ui-space-1);border:1px solid #dce4f2;border-radius:8px;background:#fff}
.skill-import-choice .skill-candidate{overflow-wrap:anywhere}
.skill-import-choice .skill-candidate:has(input:checked){background:#f3f6ff}
.skill-import-choice .skill-candidate:hover{background:#f6f8fc}
.skill-import-choice label:focus-within{outline:2px solid #5578df;outline-offset:-2px}
.skill-import-choice .helper{margin-top:var(--ui-space-2)}
.skill-import-divider{display:flex;align-items:center;gap:12px;margin:var(--ui-dialog-section-gap) 0;color:#8995a6;font-size:12px}
.skill-import-divider::before,.skill-import-divider::after{content:'';height:1px;background:#e2e7ef;flex:1}
.skill-import-file-picker{padding:14px 16px;transition:border-color .12s ease,background-color .12s ease,box-shadow .12s ease}
.skill-import-file-picker.is-dragover{border-color:#5578df;background:#eef3ff;box-shadow:0 0 0 2px rgba(85,120,223,.12)}
.skill-import-file-picker .material-file-control{padding:9px 14px;font-weight:550}
.skill-import-file-picker #skill-package-summary{margin-top:10px;overflow-wrap:anywhere}
.skill-import-progress{margin-top:var(--ui-dialog-section-gap);padding:12px 14px;border:1px solid #dce4f2;border-radius:9px;background:#f7f9fd}
.skill-import-progress[hidden]{display:none}
.skill-import-progress strong{display:block;font-size:13px;color:#26364e}
.skill-import-progress p{margin:4px 0 10px;color:#718096;font-size:11px;line-height:1.5}
.skill-import-progress progress{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%)}
.skill-import-progress-track{height:4px;overflow:hidden;border-radius:999px;background:#e4e9f2}
.skill-import-progress-track span{display:block;width:36%;height:100%;border-radius:inherit;background:#5578df;animation:skill-import-progress 1.15s ease-in-out infinite}
@keyframes skill-import-progress{from{transform:translateX(-110%)}to{transform:translateX(310%)}}
@media(prefers-reduced-motion:reduce){.skill-import-progress-track span{width:100%;animation:none}}

/* Keep manual text-resource creation compact alongside the shared tag picker. */
#dialog:has(#new-resource-name) .description{margin-bottom:12px}
#dialog:has(#new-resource-name) label{margin-top:10px}
#dialog:has(#new-resource-name) textarea{min-height:80px}
#dialog:has(#new-resource-name) .material-matches{margin-top:12px;padding:12px}
#dialog:has(#new-resource-name) .material-matches{display:flex;align-items:center;gap:12px}
#dialog:has(#new-resource-name) .material-matches h3{margin:0;white-space:nowrap}
#dialog:has(#new-resource-name) #material-matches{flex:1;min-width:0}
