/* Hashtag Toolkit panels: Cleaner & Formatter, Set Rotator, Caption Checker.
 * Everything is scoped under .bbhg-htk so it cannot leak into other panels. */
.bbhg-htk { padding: 0 4px; color: #1f2937; }
.bbhg-htk *, .bbhg-htk *::before, .bbhg-htk *::after { box-sizing: border-box; }
.bbhg-htk-header { display: flex; align-items: center; gap: 16px; padding: 22px 24px; margin-bottom: 20px; border-radius: 16px; color: #fff; background: linear-gradient(135deg, #8b5cf6 0%, #6366f1 55%, #3b82f6 100%); }
.bbhg-htk-header.is-rotate { background: linear-gradient(135deg, #6366f1 0%, #0ea5e9 60%, #14b8a6 100%); }
.bbhg-htk-header.is-check { background: linear-gradient(135deg, #7c3aed 0%, #db2777 60%, #f59e0b 100%); }
.bbhg-htk-icon { flex: none; width: 52px; height: 52px; border-radius: 14px; background: rgba(255,255,255,.2); display: flex; align-items: center; justify-content: center; }
.bbhg-htk-icon svg { width: 28px; height: 28px; stroke: #fff; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.bbhg-htk-header h2 { margin: 0 0 4px; font-size: 22px; font-weight: 700; color: #fff !important; }
.bbhg-htk-header p { margin: 0; font-size: 14px; color: rgba(255,255,255,.92) !important; }
.bbhg-htk-card { background: #fff; border: 1px solid #e5e7eb; border-radius: 16px; padding: 20px; margin-bottom: 18px; }
.bbhg-htk-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 14px; margin: 14px 0; }
.bbhg-htk label.bbhg-htk-label { display: block; font-size: 13px; font-weight: 600; color: #374151; margin-bottom: 6px; }
.bbhg-htk textarea, .bbhg-htk select, .bbhg-htk input[type=number], .bbhg-htk input[type=text] { width: 100%; border: 2px solid #e5e7eb; border-radius: 10px; background: #f9fafb; color: #1f2937; font-size: 14px; padding: 10px 12px; outline: none; font-family: inherit; }
.bbhg-htk textarea { min-height: 130px; resize: vertical; line-height: 1.5; }
.bbhg-htk textarea:focus, .bbhg-htk select:focus, .bbhg-htk input:focus { border-color: #8b5cf6; background: #fff; box-shadow: 0 0 0 3px rgba(139,92,246,.12); }
.bbhg-htk-checks { display: flex; flex-wrap: wrap; gap: 8px 18px; margin: 10px 0 4px; font-size: 13px; color: #374151; }
.bbhg-htk-checks label { display: inline-flex; align-items: center; gap: 6px; cursor: pointer; }
.bbhg-htk-row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-top: 14px; }
.bbhg-htk .bbhg-htk-btn, .bbhg-htk button.bbhg-htk-btn { border: 0 !important; border-radius: 10px; padding: 11px 20px; font-size: 14px; font-weight: 600; cursor: pointer; color: #fff !important; -webkit-text-fill-color: #fff; background: linear-gradient(135deg, #8b5cf6, #6366f1) !important; text-shadow: none; }
.bbhg-htk .bbhg-htk-btn:hover { filter: brightness(1.1); color: #fff !important; }
.bbhg-htk .bbhg-htk-btn.is-ghost, .bbhg-htk button.bbhg-htk-btn.is-ghost { background: #475569 !important; color: #fff !important; -webkit-text-fill-color: #fff; border: 0 !important; }
.bbhg-htk .bbhg-htk-btn.is-small { padding: 6px 12px; font-size: 12px; border-radius: 8px; }
.bbhg-htk-btn:focus-visible { outline: 3px solid rgba(99,102,241,.5); outline-offset: 2px; }
.bbhg-htk-out { background: #0f172a; color: #e2e8f0; border-radius: 12px; padding: 14px 16px; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 13.5px; line-height: 1.6; white-space: pre-wrap; word-break: break-word; min-height: 52px; }
.bbhg-htk-out.is-empty { color: #94a3b8; font-family: inherit; }
.bbhg-htk-stats { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0 0; }
.bbhg-htk-pill { font-size: 12px; font-weight: 600; padding: 4px 10px; border-radius: 999px; background: #ede9fe; color: #5b21b6; }
.bbhg-htk-pill.is-warn { background: #fef3c7; color: #92400e; }
.bbhg-htk-pill.is-ok { background: #dcfce7; color: #166534; }
.bbhg-htk-hint { font-size: 12.5px; color: #6b7280; margin: 8px 0 0; }
.bbhg-htk-sets { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 14px; margin-top: 14px; }
.bbhg-htk-set { border: 1px solid #e5e7eb; border-radius: 14px; padding: 14px; background: #fafafa; }
.bbhg-htk-set h4 { margin: 0 0 8px; font-size: 14px; color: #111827; display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.bbhg-htk-chip { display: inline-block; margin: 2px 4px 2px 0; padding: 3px 9px; border-radius: 999px; font-size: 12.5px; background: #ede9fe; color: #4c1d95; }
.bbhg-htk-chip.is-pinned { background: #fce7f3; color: #9d174d; }
.bbhg-htk-issues { list-style: none; margin: 14px 0 0; padding: 0; display: grid; gap: 8px; }
.bbhg-htk-issues li { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; border-radius: 10px; font-size: 13.5px; line-height: 1.45; }
.bbhg-htk-issues li b { flex: none; font-size: 11px; text-transform: uppercase; letter-spacing: .04em; padding: 2px 7px; border-radius: 6px; margin-top: 1px; }
.bbhg-htk-issues .is-error { background: #fef2f2; color: #7f1d1d; } .bbhg-htk-issues .is-error b { background: #ef4444; color: #fff; }
.bbhg-htk-issues .is-warn { background: #fffbeb; color: #78350f; } .bbhg-htk-issues .is-warn b { background: #f59e0b; color: #fff; }
.bbhg-htk-issues .is-info { background: #eff6ff; color: #1e3a8a; } .bbhg-htk-issues .is-info b { background: #3b82f6; color: #fff; }
.bbhg-htk-issues .is-pass { background: #f0fdf4; color: #14532d; } .bbhg-htk-issues .is-pass b { background: #22c55e; color: #fff; }
.bbhg-htk-verdict { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 15px; margin-bottom: 4px; }
.bbhg-htk-dot { width: 12px; height: 12px; border-radius: 50%; background: #9ca3af; }
.bbhg-htk-dot.is-pass { background: #22c55e; } .bbhg-htk-dot.is-warn { background: #f59e0b; } .bbhg-htk-dot.is-fail { background: #ef4444; }
.bbhg-htk-hl { background: #1e1b4b; color: #c7d2fe; border-radius: 12px; padding: 12px 14px; font-size: 13.5px; line-height: 1.6; white-space: pre-wrap; word-break: break-word; max-height: 220px; overflow: auto; }
.bbhg-htk-hl mark { background: #4c1d95; color: #fff; border-radius: 4px; padding: 0 3px; }
.bbhg-htk-hl mark.is-bad { background: #b91c1c; }
.bbhg-htk-toast { position: fixed; left: 50%; bottom: 28px; transform: translateX(-50%); background: #111827; color: #fff; padding: 9px 16px; border-radius: 10px; font-size: 13px; z-index: 2147483000; opacity: 0; pointer-events: none; transition: opacity .2s; }
.bbhg-htk-toast.is-on { opacity: 1; }
@media (max-width: 640px) { .bbhg-htk-header { padding: 16px; } .bbhg-htk-header h2 { font-size: 18px; } }
