.fu-tool { display: grid; grid-template-columns: minmax(0, 1fr); gap: 18px }
.fu-tool [hidden] { display: none !important }
.fu-form, .fu-fields, .fu-result { display: grid; gap: 22px }
.fu-field { display: grid; gap: 7px; min-width: 0 }
.fu-field label { color: var(--ink); font: var(--tool-label) }
.fu-field label span, .fu-help, .fu-status, .fu-list p, .fu-result > p { color: var(--tool-secondary) }
.fu-field label span { font-weight: 400 }
.fu-field input:not([type=file]), .fu-field textarea, .fu-field select {
  box-sizing: border-box; width: 100%; min-width: 0; padding: 11px 13px; border-radius: 10px;
  border: 1px solid var(--tool-border); background: var(--bg-2); color: var(--ink); font: 16px/1.5 var(--font)
}
.fu-field select { width: min(100%, 22rem); min-height: 46px }
.fu-field textarea { resize: vertical }
.fu-field textarea.fu-code { font-family: ui-monospace, monospace; font-size: 16px }
.fu-tool :is(input, textarea, select, button):focus-visible, .fu-result:focus-visible { outline: 2px solid var(--link); outline-offset: 3px }
.fu-field input[type=file] { max-width: 100%; color: var(--tool-secondary); font: inherit }
.fu-field input[type=file]::file-selector-button { margin-right: 9px; padding: 6px 12px; border: 1px solid var(--panel-line); border-radius: 8px; background: var(--card); color: var(--ink); font: inherit }
.fu-field .fu-file-label { margin-top: 6px; font-size: 14px }
.fu-help, .fu-status { font: var(--tool-caption); max-width: 75ch }
.fu-status:empty { display: none }
.fu-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 20px }
.fu-example { min-height: 44px }
.fu-tool button:disabled { opacity: .6; cursor: wait }
.fu-result { grid-template-columns: minmax(0, 1fr); gap: 16px; overflow-wrap: anywhere; scroll-margin-top: 84px }
.fu-preview { box-sizing: border-box; width: min(100%, 640px); padding: 16px 18px; background: #fff; color: #202124; border-radius: 12px; font-family: Arial, sans-serif }
.fu-preview[data-width=Mobile] { width: min(100%, 360px) }
.fu-preview-frame { max-width: 100%; overflow-x: auto; overscroll-behavior-x: contain }
.fu-preview[data-width=Desktop] { width: 640px; max-width: none }
.fu-preview-url { font-size: 13px; color: #3c4043; overflow: hidden; text-overflow: ellipsis; white-space: nowrap }
.fu-preview-title { margin: 6px 0 4px; font-size: 20px; line-height: 1.3; color: #1a0dab }
.fu-preview-description { color: #474747; font-size: 14px; line-height: 1.55 }
.fu-preview-title, .fu-preview-description { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden }
.fu-preview[data-width=Desktop] .fu-preview-title { -webkit-line-clamp: 1 }
.fu-list { display: grid; gap: 10px; padding: 0; list-style: none }
.fu-result .fu-download { justify-self: start; min-height: 44px; text-align: start }
.fu-list li { border-top: 1px solid var(--panel-line); padding-top: 12px }
.fu-list p, .fu-result > p { line-height: 1.55 }

.fu-channels { flex-wrap: wrap }
.fu-preview-site { color: #202124; font-size: 14px; line-height: 1.4 }
.fu-social-preview { width: min(100%, 540px); box-sizing: border-box; overflow: hidden; border: 1px solid var(--panel-line); border-radius: 12px; background: #f5f6f7; color: #202124 }
.fu-social-media { display: grid; place-items: center; aspect-ratio: 1.91; padding: 14px; text-align: center; color: #49525a; background: #e3e6e9; font-size: 14px; line-height: 1.45 }
.fu-social-media:has(img) { padding: 0 }
.fu-social-media img { width: 100%; height: 100%; object-fit: cover; display: block; min-height: 0 }
.fu-social-copy { padding: 12px 16px; display: grid; gap: 4px; align-content: center; min-width: 0 }
.fu-social-domain { color: #515860; font: 13px/1.4 Arial, sans-serif }
.fu-social-title, .fu-social-description { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; color: #202124 }
.fu-social-title { font: 600 18px/1.35 Arial, sans-serif }
.fu-social-description { color: #49525a; font: 14px/1.45 Arial, sans-serif }
.fu-social-preview[data-layout=compact] { display: grid; grid-template-columns: clamp(70px, 25%, 120px) minmax(0,1fr) }
.fu-social-preview[data-layout=compact] .fu-social-media { aspect-ratio: auto; min-height: 104px; font-size: 12px; padding: 6px }
.fu-social-preview[data-layout=compact] .fu-social-media:has(img) { padding: 0 }
.fu-sources { font-size: 14px }
.fu-layout-note:empty { display: none }
.fu-edit { border-top: 1px solid var(--panel-line); padding-top: 12px }
.fu-edit summary { cursor: pointer; font-weight: 600; padding-block: 4px }
.fu-edit > .fu-fields, .fu-edit > .fu-list { margin-block: 14px }
.fu-edit .uc-link { justify-self: start; min-height: 40px }

.loss-pages > li { border: 0; padding: 0 }
.loss-pages .fu-edit { padding-top: 4px }
.loss-pages summary { min-height: 44px; align-content: center }
.loss-metrics { display: grid; grid-template-columns: auto 1fr; gap: 4px 16px; margin: 8px 0 14px; font-variant-numeric: tabular-nums }
.loss-metrics dt { color: var(--tool-secondary) }
.loss-metrics dd { margin: 0 }

@media (min-width: 901px) {
  .tools-page .fu-form.fu-compare, .fu-compare .fu-edit .fu-fields { grid-template-columns: repeat(2, minmax(0, 1fr)) }
  .fu-compare > :not(.fu-field) { grid-column: 1 / -1 }
  .fu-compare > .fu-field { align-content: start }
}
