/* Màn chờ đĩa radar 3D trong Search niches (scan-radar.js). Tiền tố sr-. Selector dài vì css cũ ép nền trong suốt và màu chữ. */
html.theme-clean:not(#a):not(#b):not(#c):not(#d):not(#e) .sr-box{position:relative;display:grid;grid-template-columns:minmax(0,2.6fr) minmax(280px,1fr);height:460px;margin:0 0 18px;border-radius:20px !important;overflow:hidden;
  background-color:#0c0b12 !important;background-image:none !important;border:0 !important;box-shadow:0 30px 70px -30px rgba(35,33,44,.6);cursor:pointer;color:#fff;}
html.theme-clean:not(#a):not(#b):not(#c):not(#d):not(#e) .sr-box *{-webkit-text-fill-color:currentColor !important;opacity:1;}
.sr-stage{position:relative;min-width:0;}
.sr-stage canvas{position:absolute;inset:0;width:100% !important;height:100% !important;display:block;}
.sr-tags{position:absolute;inset:0;pointer-events:none;overflow:hidden;z-index:1;}
.sr-wait{position:absolute;inset:0;display:grid;place-items:center;font-size:13px;color:rgba(255,255,255,.55);}
html.theme-clean:not(#a):not(#b):not(#c):not(#d):not(#e) .sr-tag{position:absolute;transform:translate(-50%,-100%);padding:3px 8px;border-radius:6px !important;background-color:rgba(250,250,255,.94) !important;color:#23212C !important;-webkit-text-fill-color:#23212C !important;font-size:11px;font-weight:700;white-space:nowrap;box-shadow:0 4px 14px rgba(0,0,0,.35);animation:srIn .3s ease both;}
.sr-tag::after{content:"";position:absolute;left:50%;bottom:-4px;width:8px;height:8px;background:inherit;transform:translateX(-50%) rotate(45deg);}
html.theme-clean:not(#a):not(#b):not(#c):not(#d):not(#e) .sr-gtag{position:absolute;transform:translate(-50%,-50%);font-size:10.5px;font-weight:600;white-space:nowrap;color:rgba(220,216,255,.55) !important;-webkit-text-fill-color:rgba(220,216,255,.55) !important;background:none !important;}
@keyframes srIn{from{opacity:0;}to{opacity:1;}}
.sr-side{position:relative;display:flex;flex-direction:column;min-width:0;padding:18px 20px 16px 6px;border-left:1px solid rgba(255,255,255,.06);}
.sr-hud{display:flex;gap:20px;font-family:ui-monospace,'SF Mono',Menlo,Consolas,monospace;margin-bottom:14px;}
.sr-hud div{display:flex;flex-direction:column;}
html.theme-clean:not(#a):not(#b):not(#c):not(#d):not(#e) .sr-hud small{font-size:10px;letter-spacing:.12em;text-transform:uppercase;color:rgba(255,255,255,.42) !important;}
html.theme-clean:not(#a):not(#b):not(#c):not(#d):not(#e) .sr-hud b{font-size:19px;font-weight:700;color:#fff !important;}
html.theme-clean:not(#a):not(#b):not(#c):not(#d):not(#e) .sr-hud b.ok{color:#86efac !important;}
.sr-log{position:relative;flex:1;min-height:0;overflow:hidden;font-family:ui-monospace,'SF Mono',Menlo,Consolas,monospace;font-size:11.5px;
  -webkit-mask-image:linear-gradient(180deg,transparent 0,#000 25%);mask-image:linear-gradient(180deg,transparent 0,#000 25%);}
.sr-in{position:absolute;left:0;right:0;bottom:0;display:flex;flex-direction:column;gap:3px;}
html.theme-clean:not(#a):not(#b):not(#c):not(#d):not(#e) .sr-log p{margin:0;display:flex;justify-content:space-between;gap:10px;white-space:nowrap;color:rgba(255,255,255,.3) !important;font-size:11.5px;line-height:1.5;}
.sr-log p span{overflow:hidden;text-overflow:ellipsis;}
.sr-log p em{font-style:normal;flex:none;}
html.theme-clean:not(#a):not(#b):not(#c):not(#d):not(#e) .sr-log p.hit{color:#f4f3ff !important;}
html.theme-clean:not(#a):not(#b):not(#c):not(#d):not(#e) .sr-log p.hit em{color:#86efac !important;}
html.theme-clean:not(#a):not(#b):not(#c):not(#d):not(#e) .sr-title{margin-top:12px;font-size:14px;font-weight:700;color:#fff !important;}
html.theme-clean:not(#a):not(#b):not(#c):not(#d):not(#e) .sr-title small{display:block;margin-top:2px;font-weight:500;font-size:11px;color:rgba(255,255,255,.38) !important;}
@media (max-width:760px){
  html.theme-clean:not(#a):not(#b):not(#c):not(#d):not(#e) .sr-box{grid-template-columns:1fr;grid-template-rows:230px minmax(0,1fr);height:430px;border-radius:16px !important;}
  .sr-side{padding:8px 16px 14px;border-left:0;border-top:1px solid rgba(255,255,255,.06);}
  .sr-hud{gap:16px;margin-bottom:8px;}
}

/* Màn hình vừa: khung thấp hơn một chút */
@media (max-width:1200px) and (min-width:761px){html.theme-clean:not(#a):not(#b):not(#c):not(#d):not(#e) .sr-box{height:400px;grid-template-columns:minmax(0,1.6fr) minmax(260px,1fr);}}

/* Kênh hiếm (Rare find): viền tím sáng và nhãn riêng, chỉ khi số thật đạt ngưỡng (RARE_FIND_X trong youtube.js) */
html.theme-clean:not(#a):not(#b):not(#c):not(#d):not(#e) .nc.nc-rare{border:1.5px solid rgba(139,92,246,.55) !important;box-shadow:0 0 0 4px rgba(167,139,250,.14),0 18px 40px -18px rgba(109,106,168,.55) !important;}
html.theme-clean:not(#a):not(#b):not(#c):not(#d):not(#e) .nc-rare-tag{display:inline-flex;align-items:center;gap:6px;margin:0 0 10px;padding:5px 11px;border-radius:999px !important;font-size:12.5px;font-weight:700;
  background-image:var(--sky-c),var(--sky-b),var(--sky-a),var(--sky-milky),var(--sky-base) !important;background-size:110px 85px,125px 95px,150px 112px,100% 100%,100% 100% !important;background-color:#23212C !important;
  color:#fff !important;-webkit-text-fill-color:#fff !important;box-shadow:0 0 0 1px rgba(201,196,255,.5),0 0 16px rgba(167,139,250,.55);}
html.theme-clean:not(#a):not(#b):not(#c):not(#d):not(#e) .nc-rare-tag i{color:#c9c4ff !important;-webkit-text-fill-color:#c9c4ff !important;}
/* Nút quét: lún xuống khi bấm */
#unifiedSearchBtn,#unifiedGoBtn,#ageSplit .age-tab,.topic-chip{transition:transform .12s ease,box-shadow .12s ease;}
#unifiedSearchBtn:active,#unifiedGoBtn:active,#ageSplit .age-tab:active,.topic-chip:active{transform:scale(.95) translateY(1px);}
@media (prefers-reduced-motion:reduce){#unifiedSearchBtn:active,#unifiedGoBtn:active,#ageSplit .age-tab:active,.topic-chip:active{transform:none;}}
/* Nhãn Rare find: ruy băng gắn trên mép trên của thẻ, không chiếm chỗ nội dung */
html.theme-clean:not(#a):not(#b):not(#c):not(#d):not(#e) .nc.nc-rare{position:relative;overflow:visible !important;margin-top:14px;}
html.theme-clean:not(#a):not(#b):not(#c):not(#d):not(#e) .nc > .nc-rare-tag{position:absolute;top:-14px;left:22px;margin:0;z-index:2;width:max-content;max-width:calc(100% - 44px);}

/* "Only new breakouts" (công tắc dưới ô tìm) và nhãn "New breakout" trên thẻ kênh (sql/search-more.sql, isFreshBreakout trong youtube.js) */
html.theme-clean:not(#a):not(#b):not(#c):not(#d) .fb-only{display:inline-flex;align-items:center;gap:8px;margin-right:6px;padding:6px 12px 6px 8px;border:1px solid rgba(35,33,44,.16);border-radius:999px;background-color:#fff !important;cursor:pointer;font-size:13px;font-weight:600;color:#23212C !important;-webkit-text-fill-color:#23212C !important;user-select:none;}
html.theme-clean:not(#a):not(#b):not(#c):not(#d) .fb-only input{position:absolute;opacity:0;width:1px;height:1px;pointer-events:none;}
html.theme-clean:not(#a):not(#b):not(#c):not(#d) .fb-only .fb-sw{position:relative;flex:none;width:30px;height:18px;border-radius:999px;background-color:#d9d6e6 !important;transition:background-color .15s;}
html.theme-clean:not(#a):not(#b):not(#c):not(#d) .fb-only .fb-sw::after{content:'';position:absolute;top:2px;left:2px;width:14px;height:14px;border-radius:50%;background:#fff;box-shadow:0 1px 2px rgba(0,0,0,.25);transition:transform .15s;}
html.theme-clean:not(#a):not(#b):not(#c):not(#d) .fb-only input:checked + .fb-sw{background-color:#23212C !important;}
html.theme-clean:not(#a):not(#b):not(#c):not(#d) .fb-only input:checked + .fb-sw::after{transform:translateX(12px);}
html.theme-clean:not(#a):not(#b):not(#c):not(#d) .fb-only:has(input:checked){border-color:#23212C;}
html.theme-clean:not(#a):not(#b):not(#c):not(#d) .fb-only input:focus-visible + .fb-sw{outline:2px solid #6d6aa8;outline-offset:2px;}
html.theme-clean:not(#a):not(#b):not(#c):not(#d) .nc-badge.freshb{background:#efeef8 !important;color:#6d6aa8 !important;-webkit-text-fill-color:#6d6aa8 !important;}
html.theme-clean:not(#a):not(#b):not(#c):not(#d) .nc-badge.freshb i,html.theme-clean:not(#a):not(#b):not(#c):not(#d) .nc-badge.freshb i::before{color:#6d6aa8 !important;-webkit-text-fill-color:#6d6aa8 !important;}

/* Bốn ô chọn dưới ô tìm (Discover, Under 2 weeks old, Established, High RPM): 4 cột trên màn rộng, 2 cột trên máy tính bảng */
/* 2026-10-23: còn 3 ô (Hidden outliers lên nút trên ô tìm) */
@media (min-width:901px){ html.theme-clean:not(#a):not(#b):not(#c) .age-split{grid-template-columns:repeat(3,minmax(0,1fr));} }

/* Nút nâng cấp cạnh dòng "No free searches left" (dashboard.js randomScanRefreshUI) */
html.theme-clean:not(#a):not(#b):not(#c):not(#d) .scan-counter .sc-upg{display:inline-flex;align-items:center;gap:6px;margin-left:8px;padding:6px 12px;border:0;border-radius:999px;background-color:#fff !important;color:#23212C !important;-webkit-text-fill-color:#23212C !important;font:inherit;font-size:13px;font-weight:700;cursor:pointer;box-shadow:0 2px 10px rgba(0,0,0,.25);}
html.theme-clean:not(#a):not(#b):not(#c):not(#d) .scan-counter .sc-upg i,html.theme-clean:not(#a):not(#b):not(#c):not(#d) .scan-counter .sc-upg i::before{color:#6d6aa8 !important;-webkit-text-fill-color:#6d6aa8 !important;}
html.theme-clean:not(#a):not(#b):not(#c):not(#d) .hx-upg{display:inline-flex;align-items:center;gap:6px;padding:6px 14px;border-radius:999px;background-color:#fff !important;color:#23212C !important;-webkit-text-fill-color:#23212C !important;font-weight:700;text-decoration:none;}

/* Chữ của nút nâng cấp bị css cũ tô màu nhạt (chữ trắng trên nền trắng): selector mạnh hơn */
html.theme-clean:not(#a):not(#b):not(#c):not(#d):not(#e):not(#f) #niche-scan .scan-counter .sc-upg,
html.theme-clean:not(#a):not(#b):not(#c):not(#d):not(#e):not(#f) #niche-scan .scan-counter .sc-upg *{color:#23212C !important;-webkit-text-fill-color:#23212C !important;}
html.theme-clean:not(#a):not(#b):not(#c):not(#d):not(#e):not(#f) #niche-scan .scan-counter .sc-upg i,html.theme-clean:not(#a):not(#b):not(#c):not(#d):not(#e):not(#f) #niche-scan .scan-counter .sc-upg i::before{color:#6d6aa8 !important;-webkit-text-fill-color:#6d6aa8 !important;}
/* 4 ô dưới ô tìm (2026-10-21): nhãn giá dài ("1 search + 10 credits") đẩy chữ xuống 3 đến 4 dòng. Trên màn rộng, nhãn giá nằm DƯỚI chữ để ô bẹt lại. */
@media (min-width:901px){
  html.theme-clean:not(#a):not(#b):not(#c):not(#d) #ageSplit .age-tab{display:grid !important;grid-template-columns:auto minmax(0,1fr);grid-template-rows:auto auto;column-gap:14px;row-gap:8px;align-items:center;}
  html.theme-clean:not(#a):not(#b):not(#c):not(#d) #ageSplit .age-ic{grid-row:1 / span 2;}
  html.theme-clean:not(#a):not(#b):not(#c):not(#d) #ageSplit .age-tx{grid-column:2;}
  html.theme-clean:not(#a):not(#b):not(#c):not(#d) #ageSplit .age-tab em{grid-column:2;justify-self:start;}
}
/* Tài khoản free (2026-10-21): chỉ Fresh breakouts. Chủ đề gợi ý, nút Search và 4 ô hiện khoá, bấm vào mở bảng giá (dashboard.js freeLocked). */
html.theme-clean:not(#a):not(#b):not(#c) #niche-scan.free-locked .topic-chip,html.theme-clean:not(#a):not(#b):not(#c) #niche-scan.free-locked #unifiedGoBtn{opacity:.55;}
html.theme-clean:not(#a):not(#b):not(#c) #niche-scan.free-locked #ageSplit .age-tab.free-lock{opacity:.7;}
html.theme-clean:not(#a):not(#b):not(#c) #niche-scan.free-locked #ageSplit .age-tab.free-lock em{display:inline-flex;align-items:center;gap:4px;}
/* Nhãn "New on radar": Lynx tìm ra kênh trong 7 ngày qua (youtube.js, 2026-10-21) */
html.theme-clean:not(#a):not(#b):not(#c):not(#d) .nc-badge.newradar{background-color:#23212C !important;background-image:none !important;color:#fff !important;-webkit-text-fill-color:#fff !important;}
html.theme-clean:not(#a):not(#b):not(#c):not(#d) .nc-badge.newradar i,html.theme-clean:not(#a):not(#b):not(#c):not(#d) .nc-badge.newradar i::before{color:#fff !important;-webkit-text-fill-color:#fff !important;}
