/* Ferramentas: superfície compacta, preservando a paleta global do DarkFlow. */
body.web-tools_page .content-wrap { width: 100% !important; max-width: none !important; padding-top: 22px !important; }
body.web-tools_page .tools-workspace { width: min(1320px, 100%); margin: 0 auto; display: grid; gap: 20px; }

body.web-tools_page .hf-tools-hero { display: flex !important; align-items: center; justify-content: space-between; gap: 18px; margin: 0 !important; padding: 0 0 16px !important; border: 0 !important; border-bottom: 1px solid #22262e !important; border-radius: 0 !important; background: transparent !important; box-shadow: none !important; }
body.web-tools_page .tools-hero-copy h2 { margin: 0 0 3px !important; color: #f5f7fa; font-size: 24px !important; letter-spacing: 0 !important; }
body.web-tools_page .tools-hero-copy p { margin: 0; color: #8f96a3; font-size: 13px; }
body.web-tools_page .tools-health { display: flex; align-items: center; flex-wrap: wrap; justify-content: flex-end; gap: 14px; }
body.web-tools_page .tools-status { display: inline-flex; align-items: center; gap: 7px; color: #9da3ae; font-size: 12px; white-space: nowrap; }
body.web-tools_page .tools-status i { width: 7px; height: 7px; border-radius: 50%; background: #69707d; box-shadow: 0 0 0 3px rgba(105,112,125,.11); }
body.web-tools_page .tools-status.is-ok { color: #e5e8ed; }
body.web-tools_page .tools-status.is-ok i { background: #49c989; box-shadow: 0 0 0 3px rgba(73,201,137,.12); }
body.web-tools_page .tools-status.is-pending i { background: var(--hf-accent, #3b82f6); box-shadow: 0 0 0 3px rgba(59, 130, 246, .12); }

body.web-tools_page .operation-tabs { width: 100%; margin: 0; }
body.web-tools_page .operation-tab-list { display: flex; gap: 22px; overflow-x: auto; padding: 0; border-bottom: 1px solid #22262e; scrollbar-width: none; }
body.web-tools_page .operation-tab-list::-webkit-scrollbar { display: none; }
body.web-tools_page .operation-tab-list button { position: relative; display: inline-flex; flex: 0 0 auto; align-items: center; gap: 7px; min-height: 42px; padding: 0 0 10px; border: 0; border-radius: 0; background: transparent; color: #747b86; font-size: 12px; font-weight: 600; transition: color .16s ease; }
body.web-tools_page .operation-tab-list button:hover { color: #cfd4dc; }
body.web-tools_page .operation-tab-list button svg { width: 15px; height: 15px; }
body.web-tools_page .operation-tab-list button::after { position: absolute; right: 0; bottom: -1px; left: 0; height: 2px; border-radius: 2px 2px 0 0; background: var(--hf-accent, #3b82f6); content: ''; opacity: 0; transform: scaleX(.4); transition: opacity .16s ease, transform .16s ease; }
body.web-tools_page .operation-tab-list button.active { color: #f5f7fa; }
body.web-tools_page .operation-tab-list button.active svg { color: var(--hf-accent, #3b82f6); }
body.web-tools_page .operation-tab-list button.active::after { opacity: 1; transform: scaleX(1); }

body.web-tools_page .operation-tab-panel { display: none; padding-top: 4px; }
body.web-tools_page .operation-tab-panel.active { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 16px; }
body.web-tools_page .operation-tab-panel > .tool-card { grid-column: span 4; min-width: 0; }
body.web-tools_page .operation-tab-panel[data-operation-panel="configuracao"] > .tool-card--token { grid-column: span 8; order: -2; }
body.web-tools_page .operation-tab-panel[data-operation-panel="configuracao"] > .tool-card--oauth-app { grid-column: span 4; order: -1; }
body.web-tools_page .operation-tab-panel[data-operation-panel="configuracao"] > .tool-card--connection { grid-column: span 8; }
body.web-tools_page .operation-tab-panel[data-operation-panel="sistema"] > * { grid-column: span 6; }
body.web-tools_page .tools-section.tools-source-hidden { display: none !important; }

body.web-tools_page .tool-card,
body.web-tools_page .hf-tools-radar > *,
body.web-tools_page .api-result { min-width: 0; padding: 20px !important; border: 1px solid #20232b !important; border-radius: 12px !important; background: #101217 !important; box-shadow: none !important; transition: border-color .16s ease, background .16s ease; }
body.web-tools_page .tool-card:hover { border-color: #2c3039 !important; background: #121419 !important; }
body.web-tools_page .tool-card h2 { margin: 5px 0 6px !important; color: #f5f7fa; font-size: 17px !important; line-height: 1.25; letter-spacing: 0 !important; }
body.web-tools_page .tool-card > p { margin: 0 0 15px !important; color: #8e95a0; font-size: 12px !important; line-height: 1.52 !important; }
body.web-tools_page .tool-card--token { display: grid; grid-template-columns: 1fr; align-content: start; }
body.web-tools_page .tool-card--token > .page-kicker::before { display: inline-block; width: 17px; height: 17px; margin: -2px 7px 0 0; border-radius: 5px; background: var(--hf-accent, #3b82f6); content: ''; vertical-align: middle; }
body.web-tools_page .tool-card--token form { display: block; }
body.web-tools_page .tool-card--token .token-account-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
body.web-tools_page .tool-card--token .token-account-fields .form-label { display: block; }
body.web-tools_page .tool-card--token .form-label span { color: #6f7681; font-weight: 500; letter-spacing: 0; text-transform: none; }
body.web-tools_page .tool-card--token form button { width: max-content !important; min-width: 184px; margin-top: 4px; }
body.web-tools_page .tool-card--oauth-app .smart-list { margin-bottom: 14px !important; }
body.web-tools_page .meta-app-advanced { margin-top: 12px; border-top: 1px solid #252932; }
body.web-tools_page .meta-app-advanced summary { padding: 12px 0 2px; color: #d8dce2; cursor: pointer; font-size: 12px; font-weight: 700; }
body.web-tools_page .meta-app-advanced summary::marker { color: var(--hf-accent, #3b82f6); }
body.web-tools_page .meta-app-advanced form { padding-top: 12px; }
body.web-tools_page .meta-app-advanced form .btn { width: auto !important; }

body.web-tools_page .tool-card .form-label { margin-bottom: 5px !important; color: #abb1bb; font-size: 10px !important; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; }
body.web-tools_page .tool-card .form-control,
body.web-tools_page .tool-card .form-select { min-height: 40px !important; border: 1px solid #252932 !important; border-radius: 8px !important; background: #0b0d11 !important; color: #f5f7fa !important; font-size: 12px !important; box-shadow: none !important; }
body.web-tools_page .tool-card textarea.form-control { min-height: 72px !important; }
body.web-tools_page .tool-card .form-control::placeholder { color: #555b66 !important; }
body.web-tools_page .tool-card .form-control:focus,
body.web-tools_page .tool-card .form-select:focus { border-color: var(--hf-accent, #3b82f6) !important; box-shadow: 0 0 0 3px rgba(59, 130, 246, .12) !important; }
body.web-tools_page .tool-card .btn { display: inline-flex; width: auto !important; min-height: 39px; align-items: center; justify-content: center; padding: 8px 16px; border-radius: 8px; font-size: 12px; font-weight: 700; }
body.web-tools_page .tool-card .btn-primary { border-color: var(--hf-accent, #3b82f6) !important; background: var(--hf-accent, #3b82f6) !important; color: #fff !important; }
body.web-tools_page .tool-card .btn-outline-primary,
body.web-tools_page .tool-card .btn-outline-secondary { border-color: #292d36 !important; background: #17191f !important; color: #d8dce2 !important; }
body.web-tools_page .quick-actions.compact { display: flex !important; flex-wrap: wrap; gap: 8px !important; }
body.web-tools_page .quick-actions.compact a,
body.web-tools_page .quick-actions.compact button { display: inline-flex; width: auto !important; min-height: 36px !important; align-items: center; justify-content: center; padding: 7px 11px !important; border: 1px solid #292d36 !important; border-radius: 7px !important; background: #17191f !important; color: #d6dbe2 !important; font-size: 11px !important; line-height: 1.2 !important; text-decoration: none; }
body.web-tools_page .quick-actions.compact a:hover,
body.web-tools_page .quick-actions.compact button:hover { border-color: #3a404c !important; background: #1c1f26 !important; }

body.web-tools_page .meta-copy-list { max-height: 420px; overflow: auto !important; }
body.web-tools_page .meta-copy-list > div { padding: 10px 12px !important; border-color: #252932 !important; background: #0b0d11; }
body.web-tools_page .meta-copy-list span { display: block; margin-bottom: 4px; color: #8d94a0; font-size: 10px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; }
body.web-tools_page .meta-copy-list code { display: block; color: #e5e8ed; font-size: 11px !important; line-height: 1.4 !important; white-space: normal; word-break: break-word; }
body.web-tools_page .diagnostic-list { display: grid !important; grid-template-columns: repeat(2, minmax(0, 1fr)); overflow: hidden; border: 1px solid #252932; border-radius: 8px; background: #0b0d11; }
body.web-tools_page .diagnostic-list > div { min-height: 68px; padding: 13px !important; border: 0 !important; border-right: 1px solid #252932 !important; border-bottom: 1px solid #252932 !important; }
body.web-tools_page .diagnostic-list > div:nth-child(2n) { border-right: 0 !important; }
body.web-tools_page .diagnostic-list > div:nth-last-child(-n+2) { border-bottom: 0 !important; }

body.web-tools_page .hf-tools-radar { display: grid !important; grid-template-columns: minmax(0, 1.25fr) minmax(300px, .75fr) !important; gap: 16px !important; margin: 0 !important; }
body.web-tools_page .hf-tools-radar .smart-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; }
body.web-tools_page .hf-tools-radar .smart-card { min-height: 96px; padding: 13px !important; border-radius: 8px; }
body.web-tools_page .next-list { display: grid; gap: 6px; }
body.web-tools_page .next-row { min-height: 52px; }

body.web-tools_page .metadata-cleaner-progress { position: fixed; z-index: 1200; right: 22px; bottom: 22px; width: min(390px, calc(100vw - 32px)); pointer-events: none; opacity: 0; transform: translateY(12px); transition: opacity .2s ease, transform .2s ease; }
body.web-tools_page .metadata-cleaner-progress.is-visible { opacity: 1; transform: translateY(0); }
body.web-tools_page .metadata-progress-card { padding: 18px; border: 1px solid #292d36; border-radius: 12px; background: #101217; box-shadow: 0 18px 44px rgba(0,0,0,.35); }
body.web-tools_page .metadata-progress-mark { display: inline-flex; width: 30px; height: 30px; align-items: center; justify-content: center; margin-bottom: 10px; border-radius: 8px; background: rgba(59, 130, 246, .12); color: var(--hf-accent, #3b82f6); }
body.web-tools_page .metadata-progress-mark svg { width: 16px; height: 16px; }
body.web-tools_page .metadata-progress-card h2 { margin: 4px 0 5px; color: #f5f7fa; font-size: 16px; letter-spacing: 0; }
body.web-tools_page .metadata-progress-card p { min-height: 19px; margin: 0 0 12px; color: #969da8; font-size: 12px; line-height: 1.45; }
body.web-tools_page .metadata-progress-track { height: 5px; overflow: hidden; border-radius: 5px; background: #252932; }
body.web-tools_page .metadata-progress-track span { display: block; width: 4%; height: 100%; border-radius: inherit; background: var(--hf-accent, #3b82f6); transition: width .2s ease; }
body.web-tools_page .metadata-progress-card small { display: block; margin-top: 9px; color: #757c87; font-size: 11px; }

@media (max-width: 1080px) {
  body.web-tools_page .operation-tab-panel > .tool-card,
  body.web-tools_page .operation-tab-panel[data-operation-panel="configuracao"] > .tool-card--token,
  body.web-tools_page .operation-tab-panel[data-operation-panel="configuracao"] > .tool-card--oauth-app,
  body.web-tools_page .operation-tab-panel[data-operation-panel="configuracao"] > .tool-card--connection { grid-column: span 6; }
  body.web-tools_page .hf-tools-radar { grid-template-columns: 1fr !important; }
}
@media (max-width: 700px) {
  body.web-tools_page .content-wrap { padding: 16px !important; }
  body.web-tools_page .tools-workspace { gap: 16px; }
  body.web-tools_page .hf-tools-hero { align-items: flex-start; flex-direction: column; gap: 10px; }
  body.web-tools_page .tools-health { justify-content: flex-start; }
  body.web-tools_page .operation-tab-list { gap: 18px; }
  body.web-tools_page .operation-tab-panel.active { grid-template-columns: 1fr; gap: 12px; }
  body.web-tools_page .operation-tab-panel > .tool-card,
  body.web-tools_page .operation-tab-panel[data-operation-panel="configuracao"] > .tool-card--token,
  body.web-tools_page .operation-tab-panel[data-operation-panel="configuracao"] > .tool-card--oauth-app,
  body.web-tools_page .operation-tab-panel[data-operation-panel="configuracao"] > .tool-card--connection,
  body.web-tools_page .operation-tab-panel[data-operation-panel="sistema"] > * { grid-column: auto; }
  body.web-tools_page .tool-card,
  body.web-tools_page .hf-tools-radar > * { padding: 16px !important; }
  body.web-tools_page .tool-card--token .token-account-fields { grid-template-columns: 1fr; gap: 0; }
  body.web-tools_page .hf-tools-radar .smart-list { grid-template-columns: 1fr; }
}
