main.tgsp-legacy-active > *:not(header):not(.tgsp-legacy-page) { display: none !important; }
.tgsp-legacy-page { display: block; width: 100%; max-width: 1180px; margin: 0 auto; padding: 24px; box-sizing: border-box; color: inherit; }
.tgsp-legacy-page * { box-sizing: border-box; }
.tgsp-legacy-head { display: flex; gap: 16px; align-items: flex-start; justify-content: space-between; margin-bottom: 22px; }
.tgsp-legacy-head h1 { margin: 0 0 7px; font-size: 24px; line-height: 1.2; font-weight: 700; }
.tgsp-legacy-muted { color: #64748b; font-size: 13px; line-height: 1.55; }
.dark .tgsp-legacy-muted { color: #94a3b8; }
.tgsp-legacy-grid { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(300px, .9fr); gap: 18px; }
.tgsp-legacy-card { border: 1px solid rgba(148,163,184,.28); border-radius: 16px; background: rgba(255,255,255,.78); padding: 20px; box-shadow: 0 8px 25px rgba(15,23,42,.05); }
.dark .tgsp-legacy-card { background: rgba(15,23,42,.66); border-color: rgba(148,163,184,.22); }
.tgsp-legacy-card h2 { margin: 0 0 14px; font-size: 16px; font-weight: 700; }
.tgsp-legacy-catalog-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; gap: 12px; }
.tgsp-legacy-filters { display: grid; grid-template-columns: 2fr 1fr auto; align-items: end; gap: 12px; margin: 20px 0; }
.tgsp-legacy-field select { width: 100%; border: 1px solid #cbd5e1; border-radius: 9px; padding: 9px 10px; background: transparent; color: inherit; }
.tgsp-legacy-script-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.tgsp-legacy-script-meta { display: flex; gap: 15px; margin: 10px 0; font-size: 12px; color: #64748b; }
.tgsp-legacy-script-meta a { color: #0284c7; }
.tgsp-legacy-params { margin: 12px 0; }
.tgsp-legacy-params summary { cursor: pointer; font-size: 13px; color: #0284c7; }
.tgsp-legacy-checkbox { display: flex; gap: 8px; align-items: center; font-size: 13px; }
.tgsp-legacy-script[hidden] { display: none !important; }
.tgsp-legacy-status { display: flex; flex-wrap: wrap; gap: 9px; margin: 0 0 18px; }
.tgsp-legacy-chip { display: inline-flex; align-items: center; gap: 6px; border-radius: 999px; padding: 6px 10px; font-size: 12px; background: #f1f5f9; color: #475569; }
.dark .tgsp-legacy-chip { background: rgba(51,65,85,.7); color: #cbd5e1; }
.tgsp-legacy-chip.warn { background: #fff7ed; color: #c2410c; }
.dark .tgsp-legacy-chip.warn { background: rgba(124,45,18,.5); color: #fed7aa; }
.tgsp-legacy-chip.ok { background: #ecfdf5; color: #047857; }
.dark .tgsp-legacy-chip.ok { background: rgba(6,78,59,.5); color: #a7f3d0; }
.tgsp-legacy-script { border: 1px solid rgba(148,163,184,.25); border-radius: 13px; padding: 16px; }
.tgsp-legacy-script h3 { margin: 0 0 7px; font-size: 15px; }
.tgsp-legacy-script p { margin: 5px 0; }
.tgsp-legacy-reasons { margin: 12px 0 0; padding-left: 20px; font-size: 13px; line-height: 1.7; }
.tgsp-legacy-form { display: grid; gap: 13px; }
.tgsp-legacy-script .tgsp-legacy-form { margin-top: 14px; padding-top: 14px; border-top: 1px solid rgba(148,163,184,.2); }
.tgsp-legacy-field { display: grid; gap: 6px; font-size: 13px; }
.tgsp-legacy-field input { width: 100%; border: 1px solid #cbd5e1; border-radius: 9px; padding: 9px 10px; background: transparent; color: inherit; }
.dark .tgsp-legacy-field input { border-color: #475569; }
.tgsp-legacy-field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.tgsp-legacy-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 3px; }
.tgsp-legacy-btn { cursor: pointer; border: 0; border-radius: 9px; padding: 9px 13px; font-size: 13px; font-weight: 600; background: #e2e8f0; color: #334155; }
.tgsp-legacy-btn.primary { background: #0ea5e9; color: white; }
.tgsp-legacy-btn:disabled { cursor: not-allowed; opacity: .48; }
.dark .tgsp-legacy-btn { background: #334155; color: #e2e8f0; }
.dark .tgsp-legacy-btn.primary { background: #0284c7; color: white; }
.tgsp-legacy-alert { border-radius: 10px; padding: 10px 12px; font-size: 13px; line-height: 1.55; background: #eff6ff; color: #1d4ed8; }
.tgsp-legacy-alert.error { background: #fef2f2; color: #b91c1c; }
.dark .tgsp-legacy-alert { background: rgba(30,64,175,.28); color: #bfdbfe; }
.dark .tgsp-legacy-alert.error { background: rgba(127,29,29,.35); color: #fecaca; }
@media (max-width: 820px) { .tgsp-legacy-grid, .tgsp-legacy-catalog-list { grid-template-columns: 1fr; } .tgsp-legacy-filters { grid-template-columns: 1fr 1fr; } .tgsp-legacy-page { padding: 16px; } .tgsp-legacy-head { display: block; } }
