/* ================================================================
   IRGXYMODS — SEARCHING UNIVERSAL V3 (ULTIMATE EDITION)
   Prefix utama: .sg-*  |  Backward-compat: .srch-*
   ================================================================ */

/* ─────────── THEME TOKENS ─────────── */
:root {
  --sg-gold: #C9A96E;
  --sg-gold-light: #D4B98C;
  --sg-gold-dark: #B8946A;
  --gold-gradient: linear-gradient(135deg, #C9A96E, #D4B98C, #B8946A);
  --sg-accent: #C9A96E;
  --sg-bg-1: #0f0f1a;
  --sg-bg-2: #16162a;
  --sg-bg-3: #1a1a2e;
  --sg-surface: rgba(255,255,255,0.025);
  --sg-surface-hover: rgba(255,255,255,0.04);
  --sg-border: rgba(255,255,255,0.06);
  --sg-border-hover: rgba(201,169,110,0.35);
  --sg-text-1: #e0e0e0;
  --sg-text-2: #b0b0b0;
  --sg-text-3: #8888aa;
  --sg-radius: 16px;
  --sg-radius-sm: 10px;
  --sg-transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --sg-danger: #ff416c;
  --sg-danger-light: #ff6584;
  --sg-ok: #43e97b;
  --sg-warn: #ffc107;
  --sg-info: #4facfe;
}

/* FALLBACK untuk shared vars */
:root {
  --gold: var(--sg-gold, #d4a745);
  --gold-light: var(--sg-gold-light, #f0d78c);
  --text-primary: var(--sg-text-1, #e0e0e0);
  --text-secondary: var(--sg-text-2, #b0b0b0);
  --text-muted: var(--sg-text-3, #8888aa);
  --border-subtle: var(--sg-border, rgba(255,255,255,0.06));
  --radius: var(--sg-radius, 16px);
  --transition: var(--sg-transition);
  --font-display: 'Playfair Display', serif;
  --font-main: 'Inter', sans-serif;
}

/* NEON THEME */
html[data-theme="neon"] {
  --sg-accent: #d400ff;
  --gold-gradient: linear-gradient(135deg, #d400ff, #7b00ff, #00f0ff);
}
html[data-theme="neon"] .srch-hero-title,
html[data-theme="neon"] .sg-home-title { background: var(--gold-gradient); -webkit-background-clip: text; background-clip: text; }

/* LIGHT THEME */
html[data-theme="light"] {
  --sg-bg-1: #f5f5fa;
  --sg-bg-2: #ffffff;
  --sg-bg-3: #ffffff;
  --sg-surface: rgba(0,0,0,0.02);
  --sg-surface-hover: rgba(0,0,0,0.04);
  --sg-border: rgba(0,0,0,0.08);
  --sg-text-1: #1a1a2e;
  --sg-text-2: #4a4a5e;
  --sg-text-3: #6a6a7e;
}
html[data-theme="light"] body { background: var(--sg-bg-1); color: var(--sg-text-1); }

/* ─────────── CONTAINER ─────────── */
.sg-container { max-width: 1200px; margin: 0 auto; padding: 0 1rem 6rem; }

/* ─────────── HOME MODE ─────────── */
.sg-home-mode { animation: sgFadeUp 0.5s ease; }
.sg-home-hero { text-align: center; padding: 2rem 1rem 1.5rem; position: relative; overflow: hidden; }
.sg-home-hero::before {
  content: ''; position: absolute; top: -140px; left: 50%; transform: translateX(-50%);
  width: 480px; height: 480px;
  background: radial-gradient(circle, rgba(201,169,110,0.15) 0%, transparent 70%);
  pointer-events: none; z-index: -1;
}
.sg-home-logo {
  width: 96px; height: 96px; margin: 0 auto 1.2rem; border-radius: 26px;
  display: flex; align-items: center; justify-content: center;
  font-size: 2.6rem; color: #1a1a2e;
  background: var(--gold-gradient);
  box-shadow: 0 8px 32px rgba(201,169,110,0.35), 0 0 40px rgba(201,169,110,0.2);
  animation: sgHeroFloat 4s ease-in-out infinite;
}
.sg-home-title {
  font-family: var(--font-display); font-size: 2.4rem; font-weight: 700;
  margin-bottom: 0.5rem;
  background: var(--gold-gradient); -webkit-background-clip: text; background-clip: text; color: transparent;
  letter-spacing: 0.5px;
}
.sg-version-tag {
  display: inline-block; padding: 2px 10px; font-size: 0.9rem; vertical-align: middle;
  background: rgba(201,169,110,0.15); border: 1px solid rgba(201,169,110,0.35);
  border-radius: 20px; color: var(--sg-gold-light); -webkit-text-fill-color: initial;
  font-family: var(--font-main); font-weight: 700;
}
.sg-home-sub { color: var(--text-secondary); font-size: 1rem; max-width: 640px; margin: 0 auto 1.2rem; line-height: 1.6; }
.sg-home-pills { display: flex; justify-content: center; gap: 10px; flex-wrap: wrap; }
.sg-pill {
  display: inline-flex; align-items: center; gap: 6px; padding: 6px 14px;
  background: rgba(255,255,255,0.04); border: 1px solid var(--border-subtle);
  border-radius: 30px; font-size: 0.8rem; color: var(--text-secondary); font-weight: 500;
  transition: var(--transition); backdrop-filter: blur(8px);
}
.sg-pill:hover { border-color: rgba(201,169,110,0.35); color: var(--sg-gold-light); transform: translateY(-2px); }
.sg-pill i { color: var(--sg-gold); }

/* QUICKLINKS */
.sg-home-quicklinks { margin-top: 28px; }
.sg-home-section-title {
  font-family: var(--font-display); color: #fff; font-size: 1.05rem;
  margin-bottom: 14px; display: flex; align-items: center; gap: 10px;
}
.sg-home-section-title i { color: var(--sg-gold); }
.sg-quicklinks-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 10px;
}
.sg-quicklink {
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  padding: 16px 8px; border-radius: 14px;
  background: rgba(255,255,255,0.03); border: 1px solid var(--border-subtle);
  color: var(--text-secondary); text-decoration: none;
  font-family: var(--font-main); font-size: 0.78rem; font-weight: 600;
  transition: var(--transition);
}
.sg-quicklink:hover { transform: translateY(-4px); border-color: rgba(201,169,110,0.4); background: rgba(201,169,110,0.06); color: #fff; }
.sg-ql-icon {
  width: 38px; height: 38px; border-radius: 12px; display: flex; align-items: center; justify-content: center;
  font-size: 1.1rem; color: #fff;
}
.sg-ql-icon.google { background: linear-gradient(135deg,#4285F4,#EA4335,#FBBC05,#34A853); }
.sg-ql-icon.ddg { background: linear-gradient(135deg,#DE5833,#356178); }
.sg-ql-icon.yt { background: linear-gradient(135deg,#FF0000,#CC0000); }
.sg-ql-icon.gh { background: linear-gradient(135deg,#333,#000); }
.sg-ql-icon.wiki { background: linear-gradient(135deg,#000,#333); }
.sg-ql-icon.rd { background: linear-gradient(135deg,#FF4500,#FF8717); }
.sg-ql-icon.arch { background: linear-gradient(135deg,#6D6D6D,#000); }
.sg-ql-icon.bing { background: linear-gradient(135deg,#008272,#00B7C3); }
.sg-ql-icon.brave { background: linear-gradient(135deg,#FB542B,#FF2000); }
.sg-ql-icon.searx { background: linear-gradient(135deg,#3050FF,#00A0FF); }
.sg-ql-icon.startpage { background: linear-gradient(135deg,#5C6BC0,#3F51B5); }
.sg-ql-icon.ecosia { background: linear-gradient(135deg,#2E7D32,#1B5E20); }

/* ─────────── SEARCH BAR MEGA (dari V1) ─────────── */
.srch-bar-wrap { position: relative; margin: 1rem 0 1.5rem; z-index: 5; }
.srch-bar {
  display: flex; align-items: center; gap: 6px;
  background: rgba(22,33,62,0.55);
  backdrop-filter: blur(20px) saturate(1.5); -webkit-backdrop-filter: blur(20px) saturate(1.5);
  border: 1.5px solid var(--border-subtle); border-radius: 20px;
  padding: 8px 10px; box-shadow: 0 12px 40px rgba(0,0,0,0.4);
  transition: var(--transition); position: relative;
}
.srch-bar:focus-within {
  border-color: rgba(201,169,110,0.5);
  box-shadow: 0 12px 40px rgba(0,0,0,0.5), 0 0 0 4px rgba(201,169,110,0.1);
}
.srch-engine-select {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 10px 12px; border-radius: 12px;
  background: rgba(0,0,0,0.3); border: 1px solid var(--border-subtle);
  color: var(--text-primary); font-size: 0.85rem; font-weight: 600;
  cursor: pointer; transition: var(--transition); position: relative;
  flex-shrink: 0; user-select: none; font-family: var(--font-main);
}
.srch-engine-select:hover { border-color: rgba(201,169,110,0.4); }
.srch-engine-select i { color: var(--sg-gold); font-size: 0.9rem; }
.srch-engine-caret { font-size: 0.65rem !important; opacity: 0.6; }
.srch-engine-menu {
  position: absolute; top: calc(100% + 8px); left: 0; min-width: 260px;
  max-height: 380px; overflow-y: auto;
  background: rgba(30,30,50,0.98); backdrop-filter: blur(20px);
  border: 1px solid var(--border-subtle); border-radius: 14px; padding: 6px;
  box-shadow: 0 20px 50px rgba(0,0,0,0.5);
  opacity: 0; visibility: hidden; transform: translateY(-8px);
  transition: all 0.25s cubic-bezier(0.4,0,0.2,1); z-index: 100;
}
.srch-engine-menu.open { opacity: 1; visibility: visible; transform: translateY(0); }
.srch-engine-item {
  display: flex; align-items: center; gap: 10px; width: 100%; padding: 10px 14px;
  background: transparent; border: none; color: var(--text-primary);
  font-size: 0.85rem; font-weight: 500; cursor: pointer; border-radius: 10px;
  transition: var(--transition); text-align: left; font-family: var(--font-main);
}
.srch-engine-item:hover { background: rgba(201,169,110,0.1); color: var(--sg-gold-light); }
.srch-engine-item.active { background: rgba(201,169,110,0.15); color: var(--sg-gold-light); font-weight: 600; }
.srch-engine-item i { width: 20px; text-align: center; }
.srch-engine-item-info { display: flex; flex-direction: column; gap: 2px; flex: 1; min-width: 0; }
.srch-engine-item-name { font-weight: 600; }
.srch-engine-item-tag { font-size: 0.68rem; color: var(--sg-text-3); text-transform: uppercase; letter-spacing: 0.5px; }
.srch-bar-search-icon { color: rgba(201,169,110,0.6); font-size: 1rem; padding-left: 8px; }
.srch-input {
  flex: 1; background: transparent; border: none; outline: none;
  color: #fff; font-size: 1rem; font-family: var(--font-main);
  padding: 10px 4px; min-width: 0;
}
.srch-input::placeholder { color: rgba(255,255,255,0.4); }
.srch-mini-btn {
  width: 38px; height: 38px; border-radius: 10px;
  background: rgba(255,255,255,0.05); border: 1px solid var(--border-subtle);
  color: var(--text-secondary); cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: var(--transition); flex-shrink: 0; font-size: 0.85rem;
}
.srch-mini-btn:hover { background: rgba(201,169,110,0.15); color: var(--sg-gold-light); border-color: rgba(201,169,110,0.3); transform: translateY(-2px); }
.srch-mini-clear { color: var(--sg-danger-light); }
.srch-mini-clear:hover { background: rgba(255,65,108,0.15); color: var(--sg-danger); border-color: rgba(255,65,108,0.3); }
.srch-go-btn {
  display: inline-flex; align-items: center; gap: 8px; padding: 12px 22px;
  background: var(--gold-gradient); border: none; border-radius: 14px;
  color: #1a1a2e; font-weight: 700; font-size: 0.9rem; cursor: pointer;
  transition: var(--transition); font-family: var(--font-main);
  letter-spacing: 0.5px; box-shadow: 0 4px 16px rgba(201,169,110,0.3);
  flex-shrink: 0; white-space: nowrap;
}
.srch-go-btn:hover { transform: translateY(-2px); box-shadow: 0 8px 28px rgba(201,169,110,0.45); }

/* SUGGESTIONS */
.srch-suggest {
  position: absolute; top: calc(100% + 8px); left: 0; right: 0;
  background: rgba(30,30,50,0.98); backdrop-filter: blur(20px);
  border: 1px solid var(--border-subtle); border-radius: 16px; padding: 8px;
  box-shadow: 0 20px 50px rgba(0,0,0,0.5); max-height: 340px; overflow-y: auto;
  z-index: 90; animation: sgFadeUp 0.25s ease;
}
.srch-suggest::-webkit-scrollbar { width: 5px; }
.srch-suggest::-webkit-scrollbar-thumb { background: rgba(201,169,110,0.3); border-radius: 4px; }
.srch-sug-item {
  display: flex; align-items: center; gap: 10px; padding: 10px 14px;
  border-radius: 10px; color: var(--text-secondary); cursor: pointer;
  font-size: 0.88rem; transition: var(--transition);
}
.srch-sug-item:hover, .srch-sug-item.active { background: rgba(201,169,110,0.1); color: #fff; }
.srch-sug-item i { color: rgba(201,169,110,0.6); font-size: 0.8rem; }
.srch-mark { background: rgba(201,169,110,0.3); color: var(--sg-gold-light); border-radius: 4px; padding: 0 3px; font-weight: 600; }

/* QUICK TAGS */
.srch-quicktags { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin-top: 14px; }
.srch-qtag {
  padding: 8px 14px; background: rgba(255,255,255,0.04);
  border: 1px solid var(--border-subtle); border-radius: 30px;
  color: var(--text-secondary); font-size: 0.8rem; font-weight: 500;
  cursor: pointer; transition: var(--transition); font-family: var(--font-main);
}
.srch-qtag:hover { background: rgba(201,169,110,0.12); color: var(--sg-gold-light); border-color: rgba(201,169,110,0.35); transform: translateY(-2px); }

/* TOOLBAR TOOL-CARDS */
.srch-toolbar { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 12px; margin-bottom: 1.8rem; margin-top: 1.8rem; }
.srch-tool-card {
  display: flex; align-items: center; gap: 12px; padding: 14px 16px;
  background: rgba(255,255,255,0.03);
  backdrop-filter: blur(15px); -webkit-backdrop-filter: blur(15px);
  border: 1px solid var(--border-subtle); border-radius: 14px;
  cursor: pointer; transition: var(--transition); position: relative; overflow: hidden;
}
.srch-tool-card::before {
  content: ''; position: absolute; top: 0; left: 0; width: 3px; height: 100%;
  background: var(--gold-gradient); opacity: 0.6; transition: opacity 0.3s;
}
.srch-tool-card:hover { transform: translateY(-3px); border-color: rgba(201,169,110,0.3); box-shadow: 0 12px 30px rgba(0,0,0,0.35), 0 0 20px rgba(201,169,110,0.1); }
.srch-tool-card:focus-visible { outline: 2px solid var(--sg-gold); outline-offset: 2px; }
.srch-tool-icon {
  width: 40px; height: 40px; border-radius: 12px;
  background: linear-gradient(135deg, rgba(201,169,110,0.18), rgba(201,169,110,0.04));
  border: 1px solid rgba(201,169,110,0.2);
  display: flex; align-items: center; justify-content: center;
  color: var(--sg-gold); font-size: 1rem; flex-shrink: 0; transition: transform 0.3s ease;
}
.srch-tool-card:hover .srch-tool-icon { transform: scale(1.08) rotate(-4deg); }
.srch-tool-info { flex: 1; min-width: 0; }
.srch-tool-name { font-size: 0.85rem; font-weight: 600; color: #fff; line-height: 1.2; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.srch-tool-sub { font-size: 0.7rem; color: var(--sg-text-3); margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.srch-toggle-pill {
  font-size: 0.6rem; font-weight: 700; padding: 3px 9px; border-radius: 20px;
  background: rgba(255,255,255,0.06); color: var(--sg-text-3); letter-spacing: 0.5px; flex-shrink: 0;
}
.srch-toggle-pill.active { background: rgba(67,233,123,0.15); color: var(--sg-ok); border: 1px solid rgba(67,233,123,0.3); }

/* ─────────── BROWSER MODE ─────────── */
.sg-browser-mode { animation: sgFadeUp 0.4s ease; }

/* Rename V2 toolbar → sg-browser-bar untuk hindari konflik dengan .srch-toolbar */
.sg-browser-bar {
  display: flex; align-items: center; gap: 10px;
  background: rgba(255,255,255,0.04);
  backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--border-subtle); border-radius: 50px;
  padding: 8px 12px; margin: 1.2rem 0 1rem;
  position: sticky; top: 8px; z-index: 80;
  box-shadow: 0 12px 40px rgba(0,0,0,0.35);
}
.sg-browser-bar-left, .sg-browser-bar-right { display: flex; gap: 4px; flex-shrink: 0; }
.sg-tool-btn {
  width: 38px; height: 38px; border-radius: 50%;
  background: transparent; border: 1px solid transparent;
  color: var(--text-secondary); cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.9rem; transition: var(--transition);
}
.sg-tool-btn:hover:not(:disabled) { background: rgba(255,255,255,0.08); color: #fff; border-color: var(--border-subtle); transform: translateY(-1px); }
.sg-tool-btn:disabled { opacity: 0.35; cursor: not-allowed; }
.sg-tool-btn.active { color: var(--sg-gold); background: rgba(201,169,110,0.12); border-color: rgba(201,169,110,0.3); }
.sg-tool-btn:focus-visible { outline: 2px solid var(--sg-gold); outline-offset: 2px; }

.sg-mini-searchbar {
  position: relative; flex: 1; display: flex; align-items: center;
  background: rgba(0,0,0,0.4); border: 1.5px solid var(--border-subtle);
  border-radius: 30px; padding: 0 6px 0 42px;
  transition: var(--transition); min-width: 0;
}
.sg-mini-searchbar:focus-within {
  border-color: rgba(201,169,110,0.55); background: rgba(0,0,0,0.5);
  box-shadow: 0 0 0 4px rgba(201,169,110,0.12), 0 0 30px rgba(201,169,110,0.15);
}
.sg-mini-searchbar-icon {
  position: absolute; left: 16px; top: 50%; transform: translateY(-50%);
  color: var(--sg-gold); font-size: 0.9rem; pointer-events: none;
}
.sg-mini-searchbar-input {
  flex: 1; min-width: 0; padding: 13px 8px;
  background: transparent; border: none; outline: none;
  font-family: var(--font-main); font-size: 0.92rem; color: #fff;
}
.sg-mini-searchbar-input::placeholder { color: rgba(255,255,255,0.4); }
.sg-mini-searchbar-go {
  width: 34px; height: 34px; border-radius: 50%; border: none;
  background: var(--gold-gradient); color: #1a1a2e; font-weight: 700;
  cursor: pointer; display: flex; align-items: center; justify-content: center;
  transition: var(--transition); flex-shrink: 0;
}
.sg-mini-searchbar-go:hover { transform: scale(1.08); box-shadow: 0 4px 14px rgba(201,169,110,0.5); }

/* TABS */
.sg-tabsbar { display: flex; align-items: center; gap: 6px; margin-bottom: 10px; overflow-x: auto; scrollbar-width: none; }
.sg-tabsbar::-webkit-scrollbar { display: none; }
.sg-tabs { display: flex; gap: 6px; flex: 1; min-width: 0; }
.sg-tab {
  display: flex; align-items: center; gap: 8px; padding: 9px 12px;
  border-radius: 12px; background: rgba(255,255,255,0.03);
  border: 1px solid var(--border-subtle); color: var(--text-secondary);
  cursor: pointer; font-family: var(--font-main); font-size: 0.8rem;
  min-width: 160px; max-width: 240px;
  transition: var(--transition); position: relative;
}
.sg-tab:hover { background: rgba(255,255,255,0.06); color: #fff; }
.sg-tab.active {
  background: linear-gradient(135deg, rgba(201,169,110,0.15), rgba(201,169,110,0.03));
  border-color: rgba(201,169,110,0.4); color: #fff;
  box-shadow: 0 4px 14px rgba(201,169,110,0.15);
}
.sg-tab.active::after {
  content: ''; position: absolute; bottom: -1px; left: 12px; right: 12px;
  height: 2px; background: var(--gold-gradient); border-radius: 2px;
}
.sg-tab.pinned { border-color: rgba(201,169,110,0.5); min-width: 60px; max-width: 60px; justify-content: center; padding: 9px 6px; }
.sg-tab.pinned .sg-tab-title, .sg-tab.pinned .sg-tab-close { display: none; }
.sg-tab.discarded { opacity: 0.5; }
.sg-tab-favicon { width: 16px; height: 16px; flex-shrink: 0; display: flex; align-items: center; justify-content: center; font-size: 0.7rem; color: var(--sg-gold); }
.sg-tab-title { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sg-tab-close {
  width: 18px; height: 18px; border-radius: 50%; background: transparent; border: none;
  color: var(--sg-text-3); cursor: pointer; display: flex; align-items: center; justify-content: center;
  font-size: 0.65rem; flex-shrink: 0; transition: all 0.2s ease;
}
.sg-tab-close:hover { background: rgba(255,65,108,0.2); color: var(--sg-danger-light); }
.sg-tab.loading .sg-tab-favicon i { animation: sgSpin 0.8s linear infinite; }
.sg-tab-add {
  width: 36px; height: 36px; border-radius: 50%;
  background: rgba(255,255,255,0.04); border: 1px solid var(--border-subtle);
  color: var(--text-secondary); cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.85rem; flex-shrink: 0; transition: var(--transition);
}
.sg-tab-add:hover { background: rgba(201,169,110,0.15); color: var(--sg-gold); border-color: rgba(201,169,110,0.4); transform: rotate(90deg); }

/* VIEWPORT */
.sg-viewport-wrap { margin-bottom: 2rem; position: relative; border-radius: 20px; overflow: hidden; }
.sg-viewport {
  position: relative; min-height: 520px; background: rgba(255,255,255,0.02);
  border: 1px solid var(--border-subtle); border-radius: 20px;
  overflow: hidden; display: flex; flex-direction: column;
}
.sg-browser { flex: 1; position: relative; display: flex; flex-direction: column; min-height: 520px; }
.sg-browser-overlay {
  position: absolute; inset: 0; z-index: 10;
  background: radial-gradient(ellipse at center, rgba(26,26,46,0.96), rgba(15,15,26,0.98));
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  display: none; flex-direction: column; align-items: center; justify-content: center; padding: 24px;
}
.sg-browser-overlay.show { display: flex; animation: sgFadeIn 0.3s ease; }
.sg-frame { width: 100%; flex: 1; border: none; background: #fff; min-height: 520px; }

/* MODERN LOADER 3-ORBIT */
.sg-loader { position: relative; width: 120px; height: 120px; display: flex; align-items: center; justify-content: center; margin-bottom: 24px; }
.sg-loader-orbit { position: absolute; border-radius: 50%; border: 2.5px solid transparent; animation: sgSpin 1.4s linear infinite; }
.sg-loader-orbit:nth-child(1) { inset: 0; border-top-color: #C9A96E; border-right-color: rgba(201,169,110,0.3); }
.sg-loader-orbit:nth-child(2) { inset: 14px; border-bottom-color: #d400ff; border-left-color: rgba(212,0,255,0.3); animation-duration: 1.8s; animation-direction: reverse; }
.sg-loader-orbit:nth-child(3) { inset: 28px; border-top-color: #00f0ff; border-right-color: rgba(0,240,255,0.3); animation-duration: 2.2s; }
.sg-loader-core {
  width: 56px; height: 56px; border-radius: 50%;
  background: var(--gold-gradient); display: flex; align-items: center; justify-content: center;
  font-size: 1.3rem; color: #1a1a2e;
  box-shadow: 0 0 30px rgba(201,169,110,0.6), 0 0 60px rgba(201,169,110,0.3);
  animation: sgPulse 1.6s ease-in-out infinite;
}
.sg-loader-pct {
  position: absolute; bottom: -20px; left: 50%; transform: translateX(-50%);
  font-family: 'JetBrains Mono', monospace; font-size: 0.75rem; color: var(--sg-gold);
  font-weight: 700; letter-spacing: 1px;
}
.sg-loader-text { color: var(--text-secondary); font-size: 0.9rem; font-family: var(--font-main); margin-bottom: 14px; text-align: center; }
.sg-loader-bar { width: min(280px, 80vw); height: 4px; background: rgba(255,255,255,0.06); border-radius: 4px; overflow: hidden; }
.sg-loader-fill {
  height: 100%; width: 0%; border-radius: 4px;
  background: linear-gradient(90deg, #B8946A, #D4B98C, #C9A96E, #B8946A);
  background-size: 200% auto; animation: sgShine 2s linear infinite;
  transition: width 0.3s ease;
}

/* FIND IN PAGE BAR */
.sg-find-bar {
  position: absolute; top: 12px; right: 12px; z-index: 20;
  display: flex; align-items: center; gap: 6px;
  background: rgba(20,20,32,0.98); backdrop-filter: blur(16px);
  border: 1px solid rgba(201,169,110,0.3); border-radius: 12px;
  padding: 6px 8px; box-shadow: 0 10px 30px rgba(0,0,0,0.5);
  animation: sgFadeDown 0.25s ease;
}
.sg-find-bar input {
  padding: 6px 10px; background: rgba(0,0,0,0.3);
  border: 1px solid var(--border-subtle); border-radius: 8px;
  color: #fff; font-size: 0.8rem; outline: none; width: 180px;
}
.sg-find-bar input:focus { border-color: rgba(201,169,110,0.5); }
.sg-find-count { font-family: 'JetBrains Mono', monospace; font-size: 0.72rem; color: var(--sg-gold); min-width: 40px; text-align: center; }
.sg-find-bar button {
  width: 26px; height: 26px; border-radius: 6px;
  background: rgba(255,255,255,0.05); border: 1px solid var(--border-subtle);
  color: var(--text-secondary); cursor: pointer; font-size: 0.7rem;
  display: flex; align-items: center; justify-content: center;
  transition: var(--transition);
}
.sg-find-bar button:hover { color: var(--sg-gold); border-color: rgba(201,169,110,0.4); }

/* BLOCKED SCREEN */
.sg-blocked {
  flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: 40px 24px; text-align: center;
  background: radial-gradient(ellipse at center, rgba(255,65,108,0.08), transparent 70%);
  animation: sgShake 0.5s ease;
}
.sg-blocked-icon {
  width: 96px; height: 96px; border-radius: 28px;
  background: linear-gradient(135deg, rgba(255,65,108,0.15), rgba(255,65,108,0.03));
  border: 2px solid rgba(255,65,108,0.35); color: var(--sg-danger-light);
  font-size: 2.4rem; display: flex; align-items: center; justify-content: center;
  margin-bottom: 20px; animation: sgFloat 3s ease-in-out infinite;
}
.sg-blocked-title { font-family: var(--font-display); color: #fff; font-size: 1.6rem; margin-bottom: 8px; }
.sg-blocked-sub { color: var(--text-secondary); font-size: 0.92rem; max-width: 520px; margin-bottom: 20px; line-height: 1.65; }
.sg-blocked-reasons { display: flex; flex-direction: column; gap: 6px; margin-bottom: 24px; max-width: 520px; width: 100%; }
.sg-blocked-reason {
  display: flex; align-items: center; gap: 10px; padding: 10px 14px;
  border-radius: 10px; background: rgba(255,65,108,0.08);
  border: 1px solid rgba(255,65,108,0.25); color: var(--sg-danger-light);
  font-size: 0.85rem; text-align: left;
}
.sg-blocked-actions { display: flex; gap: 10px; flex-wrap: wrap; justify-content: center; }

/* BUTTONS */
.sg-btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 12px 22px; border-radius: 30px; border: none;
  font-family: var(--font-main); font-size: 0.85rem; font-weight: 700;
  cursor: pointer; transition: var(--transition);
}
.sg-btn:hover { transform: translateY(-2px); }
.sg-btn-primary { background: var(--gold-gradient); color: #1a1a2e; box-shadow: 0 6px 20px rgba(201,169,110,0.35); }
.sg-btn-primary:hover { box-shadow: 0 10px 28px rgba(201,169,110,0.5); }
.sg-btn-danger { background: rgba(255,65,108,0.12); border: 1px solid rgba(255,65,108,0.35); color: var(--sg-danger-light); }
.sg-btn-danger:hover { background: rgba(255,65,108,0.2); }
.sg-btn-secondary { background: rgba(255,255,255,0.06); border: 1px solid var(--border-subtle); color: #fff; }

/* ─────────── PANEL UMUM (dari V1) ─────────── */
.srch-result-panel, .srch-sec-dashboard, .srch-bypass-panel, .srch-bm-panel {
  background: rgba(255,255,255,0.025);
  backdrop-filter: blur(15px); -webkit-backdrop-filter: blur(15px);
  border: 1px solid var(--border-subtle); border-radius: var(--radius);
  padding: 22px; margin-bottom: 1.8rem;
  box-shadow: 0 12px 32px rgba(0,0,0,0.25);
  position: relative; overflow: hidden;
}
.srch-result-panel::before, .srch-sec-dashboard::before,
.srch-bypass-panel::before, .srch-bm-panel::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px;
  background: var(--gold-gradient); opacity: 0.75;
}
.srch-panel-head { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 10px; margin-bottom: 16px; }
.srch-panel-title { font-family: var(--font-display); font-size: 1.25rem; font-weight: 700; color: #fff; display: flex; align-items: center; gap: 10px; margin: 0; }
.srch-panel-title i { color: var(--sg-gold); }
.srch-panel-status {
  font-size: 0.7rem; text-transform: uppercase; letter-spacing: 1px;
  color: var(--sg-text-3); padding: 5px 12px;
  background: rgba(255,255,255,0.04); border-radius: 20px; border: 1px solid var(--border-subtle);
}

/* Empty/Error/Skeleton */
.srch-empty, .srch-error { text-align: center; padding: 40px 20px; }
.srch-empty i, .srch-error i { font-size: 3rem; color: rgba(201,169,110,0.3); margin-bottom: 14px; display: block; }
.srch-error i { color: rgba(255,101,132,0.5); }
.srch-empty h3, .srch-error h3 { color: #fff; font-size: 1.05rem; margin-bottom: 6px; font-weight: 600; }
.srch-empty p, .srch-error p { color: var(--sg-text-3); font-size: 0.85rem; max-width: 400px; margin: 0 auto; }
.srch-retry-btn {
  margin-top: 16px; padding: 10px 22px; background: var(--gold-gradient);
  border: none; border-radius: 30px; color: #1a1a2e; font-weight: 700;
  font-size: 0.85rem; cursor: pointer; transition: var(--transition); font-family: var(--font-main);
}
.srch-retry-btn:hover { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(201,169,110,0.4); }
.srch-skeleton { display: grid; gap: 12px; }
.srch-skel-row {
  height: 78px; border-radius: 12px;
  background: linear-gradient(90deg, rgba(255,255,255,0.02) 0%, rgba(201,169,110,0.12) 50%, rgba(255,255,255,0.02) 100%);
  background-size: 200% 100%; animation: sgShimmer 1.4s linear infinite;
}
.srch-results { display: grid; gap: 12px; }
.srch-res-card {
  display: flex; gap: 14px; padding: 16px;
  background: rgba(255,255,255,0.02); border: 1px solid var(--border-subtle);
  border-radius: 14px; transition: var(--transition);
  animation: sgFadeUp 0.4s ease forwards; opacity: 0;
}
.srch-res-card:hover { transform: translateY(-3px); border-color: rgba(201,169,110,0.25); background: rgba(255,255,255,0.04); box-shadow: 0 12px 30px rgba(0,0,0,0.3); }
.srch-res-fav {
  width: 42px; height: 42px; border-radius: 10px;
  background: rgba(201,169,110,0.08); border: 1px solid rgba(201,169,110,0.15);
  display: flex; align-items: center; justify-content: center;
  color: var(--sg-gold); font-size: 1.1rem; flex-shrink: 0; overflow: hidden;
}
.srch-res-fav img { width: 100%; height: 100%; object-fit: cover; }
.srch-res-body { flex: 1; min-width: 0; }
.srch-res-title { font-size: 0.95rem; font-weight: 700; color: #fff; margin-bottom: 4px; line-height: 1.3; }
.srch-res-url { font-size: 0.75rem; color: var(--sg-gold-light); margin-bottom: 6px; word-break: break-all; opacity: 0.85; }
.srch-res-snippet { font-size: 0.82rem; color: var(--text-secondary); line-height: 1.5; margin-bottom: 10px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.srch-res-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.srch-res-btn {
  padding: 7px 14px; background: rgba(255,255,255,0.05);
  border: 1px solid var(--border-subtle); border-radius: 20px;
  color: var(--text-secondary); font-size: 0.75rem; font-weight: 600;
  cursor: pointer; transition: var(--transition); font-family: var(--font-main);
  display: inline-flex; align-items: center; gap: 5px;
}
.srch-res-btn:hover { background: rgba(201,169,110,0.12); color: var(--sg-gold-light); border-color: rgba(201,169,110,0.3); transform: translateY(-2px); }
.srch-res-btn.primary { background: var(--gold-gradient); color: #1a1a2e; border-color: transparent; font-weight: 700; }

/* ─────────── SECURITY DASHBOARD ─────────── */
.srch-sec-grid { display: grid; grid-template-columns: 200px 1fr; gap: 22px; align-items: center; margin-bottom: 16px; }
.srch-sec-score-wrap { position: relative; width: 180px; height: 180px; margin: 0 auto; }
.srch-score-svg { width: 100%; height: 100%; }
.srch-score-center { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.srch-score-num {
  font-family: var(--font-display); font-size: 2.4rem; font-weight: 700;
  background: var(--gold-gradient); -webkit-background-clip: text; background-clip: text; color: transparent; line-height: 1;
}
.srch-score-label { font-size: 0.65rem; text-transform: uppercase; letter-spacing: 1.5px; color: var(--sg-text-3); margin-top: 4px; text-align: center; }
.srch-sec-tests { display: grid; gap: 8px; }
.srch-sec-test {
  display: flex; align-items: center; gap: 10px; padding: 10px 14px;
  background: rgba(0,0,0,0.2); border: 1px solid var(--border-subtle);
  border-radius: 10px; font-size: 0.82rem;
}
.srch-sec-dot { width: 8px; height: 8px; border-radius: 50%; background: #8888aa; flex-shrink: 0; animation: sgDotPulse 1.8s ease-in-out infinite; }
.srch-sec-dot.ok { background: var(--sg-ok); box-shadow: 0 0 10px rgba(67,233,123,0.6); }
.srch-sec-dot.warn { background: var(--sg-warn); box-shadow: 0 0 10px rgba(255,193,7,0.5); }
.srch-sec-dot.bad { background: var(--sg-danger); box-shadow: 0 0 10px rgba(255,65,108,0.5); }
.srch-sec-test-name { flex: 1; color: var(--text-secondary); }
.srch-sec-test-val { font-size: 0.7rem; font-weight: 700; letter-spacing: 0.5px; text-transform: uppercase; }
.srch-sec-test-val.ok { color: var(--sg-ok); }
.srch-sec-test-val.warn { color: var(--sg-warn); }
.srch-sec-test-val.bad { color: var(--sg-danger); }
.srch-sec-test-val.idle { color: var(--sg-text-3); }
.srch-sec-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 16px; }
.srch-primary-btn, .srch-gold-btn, .srch-danger-btn, .srch-secondary-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 11px 20px; border-radius: 30px; border: 1px solid var(--border-subtle);
  background: rgba(255,255,255,0.05); color: var(--text-primary);
  font-weight: 600; font-size: 0.82rem; cursor: pointer;
  transition: var(--transition); font-family: var(--font-main);
}
.srch-primary-btn:hover, .srch-secondary-btn:hover { background: rgba(201,169,110,0.12); color: var(--sg-gold-light); border-color: rgba(201,169,110,0.35); transform: translateY(-2px); }
.srch-gold-btn { background: var(--gold-gradient); color: #1a1a2e; border: none; font-weight: 700; box-shadow: 0 6px 20px rgba(201,169,110,0.3); }
.srch-gold-btn:hover { transform: translateY(-2px); box-shadow: 0 10px 28px rgba(201,169,110,0.45); }
.srch-danger-btn { background: rgba(255,65,108,0.1); border: 1px solid rgba(255,65,108,0.25); color: var(--sg-danger-light); }
.srch-danger-btn:hover { background: rgba(255,65,108,0.2); transform: translateY(-2px); }

/* LOG */
.srch-log-wrap { background: #0a0a14; border-radius: 12px; border: 1px solid rgba(201,169,110,0.15); overflow: hidden; }
.srch-log-head {
  display: flex; justify-content: space-between; align-items: center; padding: 8px 14px;
  background: rgba(201,169,110,0.06); border-bottom: 1px solid rgba(201,169,110,0.15);
  font-size: 0.7rem; font-weight: 700; letter-spacing: 1px; text-transform: uppercase; color: var(--sg-gold-light);
}
.srch-log-head i { margin-right: 6px; }
.srch-log-clear { background: none; border: none; color: var(--sg-text-3); cursor: pointer; font-size: 0.7rem; font-family: var(--font-main); transition: color 0.3s; }
.srch-log-clear:hover { color: var(--sg-danger-light); }
.srch-log { max-height: 200px; overflow-y: auto; padding: 10px 14px; font-family: 'JetBrains Mono', monospace; font-size: 0.75rem; line-height: 1.6; color: #b0b0b0; }
.srch-log::-webkit-scrollbar { width: 4px; }
.srch-log::-webkit-scrollbar-thumb { background: rgba(201,169,110,0.3); border-radius: 4px; }
.srch-log-line { white-space: pre-wrap; word-break: break-all; animation: sgFadeIn 0.3s ease; }
.srch-log-line .ts { color: var(--sg-text-3); }
.srch-log-line.info .lv { color: var(--sg-info); }
.srch-log-line.ok .lv { color: var(--sg-ok); }
.srch-log-line.warn .lv { color: var(--sg-warn); }
.srch-log-line.error .lv { color: var(--sg-danger); }

/* ─────────── BYPASS PANEL ─────────── */
.srch-bypass-input-row { display: flex; gap: 10px; margin-bottom: 14px; flex-wrap: wrap; }
.srch-input-flat {
  flex: 1; min-width: 200px; padding: 12px 16px;
  background: rgba(0,0,0,0.3); border: 1.5px solid var(--border-subtle);
  border-radius: 12px; color: #fff; font-size: 0.9rem;
  font-family: var(--font-main); outline: none; transition: var(--transition);
}
.srch-input-flat:focus { border-color: rgba(201,169,110,0.5); box-shadow: 0 0 0 3px rgba(201,169,110,0.1); }
.srch-input-flat::placeholder { color: rgba(255,255,255,0.4); }
.srch-bypass-presets { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.srch-preset-label { font-size: 0.75rem; color: var(--sg-text-3); font-weight: 600; margin-right: 4px; }
.srch-preset-btn {
  padding: 6px 14px; background: rgba(255,255,255,0.04);
  border: 1px solid var(--border-subtle); border-radius: 20px;
  color: var(--text-secondary); font-size: 0.75rem; font-weight: 500;
  cursor: pointer; transition: var(--transition); font-family: var(--font-main);
}
.srch-preset-btn:hover { background: rgba(201,169,110,0.12); color: var(--sg-gold-light); border-color: rgba(201,169,110,0.3); transform: translateY(-2px); }
.srch-bypass-result { margin-top: 16px; padding-top: 16px; border-top: 1px dashed rgba(255,255,255,0.08); }
.srch-bypass-url { font-size: 0.82rem; color: var(--sg-gold-light); margin-bottom: 10px; word-break: break-all; }
.srch-bypass-proxies { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 8px; }

/* ─────────── BOOKMARK PANEL ─────────── */
.srch-tab-row { display: flex; gap: 6px; flex-wrap: wrap; }
.srch-tab-btn {
  padding: 8px 16px; background: rgba(255,255,255,0.04);
  border: 1px solid var(--border-subtle); border-radius: 30px;
  color: var(--text-secondary); font-size: 0.78rem; font-weight: 600;
  cursor: pointer; transition: var(--transition); font-family: var(--font-main);
  display: inline-flex; align-items: center; gap: 6px;
}
.srch-tab-btn:hover { color: #fff; border-color: rgba(201,169,110,0.3); }
.srch-tab-btn.active { background: var(--gold-gradient); color: #1a1a2e; border-color: transparent; font-weight: 700; }
.srch-tab-pane { display: none; }
.srch-tab-pane.active { display: block; }
.srch-list { display: flex; flex-direction: column; gap: 8px; margin-bottom: 12px; max-height: 340px; overflow-y: auto; }
.srch-list::-webkit-scrollbar { width: 5px; }
.srch-list::-webkit-scrollbar-thumb { background: rgba(201,169,110,0.3); border-radius: 4px; }
.srch-list-item {
  display: flex; align-items: center; gap: 12px; padding: 11px 14px;
  background: rgba(255,255,255,0.02); border: 1px solid var(--border-subtle);
  border-radius: 10px; transition: var(--transition);
}
.srch-list-item:hover { background: rgba(201,169,110,0.06); border-color: rgba(201,169,110,0.2); }
.srch-list-icon {
  width: 32px; height: 32px; border-radius: 50%;
  background: rgba(201,169,110,0.12); color: var(--sg-gold);
  display: flex; align-items: center; justify-content: center;
  font-size: 0.75rem; flex-shrink: 0;
}
.srch-list-body { flex: 1; min-width: 0; }
.srch-list-title { font-size: 0.82rem; color: #fff; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.srch-list-meta { font-size: 0.7rem; color: var(--sg-text-3); margin-top: 2px; }
.srch-list-actions { display: flex; gap: 6px; }
.srch-icon-btn {
  width: 28px; height: 28px; border-radius: 8px;
  background: rgba(255,255,255,0.04); border: 1px solid var(--border-subtle);
  color: var(--sg-text-3); cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.7rem; transition: var(--transition);
}
.srch-icon-btn:hover { color: var(--sg-danger-light); border-color: rgba(255,65,108,0.3); }
.srch-clear-btn {
  width: 100%; padding: 10px; background: rgba(255,65,108,0.06);
  border: 1px solid rgba(255,65,108,0.15); border-radius: 10px;
  color: var(--sg-danger-light); font-size: 0.78rem; font-weight: 600;
  cursor: pointer; transition: var(--transition); font-family: var(--font-main);
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
}
.srch-clear-btn:hover { background: rgba(255,65,108,0.15); transform: translateY(-2px); }

/* ─────────── INFO CARDS ─────────── */
.srch-info-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; margin-bottom: 2rem; }
.srch-info-card {
  background: rgba(255,255,255,0.03); border: 1px solid var(--border-subtle);
  border-radius: var(--radius); padding: 22px; text-align: center;
  transition: var(--transition); position: relative; overflow: hidden;
}
.srch-info-card::before { content: ''; position: absolute; top: 0; left: 0; right: 0; height: 2px; background: var(--gold-gradient); opacity: 0.7; }
.srch-info-card:hover { transform: translateY(-6px); border-color: rgba(201,169,110,0.3); box-shadow: 0 16px 40px rgba(0,0,0,0.35); }
.srch-info-icon { font-size: 2rem; margin-bottom: 12px; background: var(--gold-gradient); -webkit-background-clip: text; background-clip: text; color: transparent; }
.srch-info-card h3 { font-family: var(--font-display); color: #fff; font-size: 1.1rem; font-weight: 700; margin-bottom: 8px; }
.srch-info-card p { color: var(--text-secondary); font-size: 0.85rem; line-height: 1.6; }

/* ─────────── DRAWER ─────────── */
.srch-drawer-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,0.6);
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
  z-index: 9998; opacity: 0; visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}
.srch-drawer-overlay.open { opacity: 1; visibility: visible; }
.srch-drawer {
  position: fixed; top: 0; right: 0; width: 420px; max-width: 92vw; height: 100vh;
  background: rgba(20,20,32,0.98); backdrop-filter: blur(24px); -webkit-backdrop-filter: blur(24px);
  border-left: 1px solid var(--border-subtle); box-shadow: -20px 0 60px rgba(0,0,0,0.5);
  z-index: 9999; transform: translateX(100%);
  transition: transform 0.4s cubic-bezier(0.22, 1, 0.36, 1);
  display: flex; flex-direction: column; overflow: hidden;
}
.srch-drawer.open { transform: translateX(0); }
.srch-drawer::before { content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 3px; background: var(--gold-gradient); }
.srch-drawer-head { display: flex; justify-content: space-between; align-items: center; padding: 20px 22px 14px; border-bottom: 1px solid var(--border-subtle); }
.srch-drawer-head h3 { font-family: var(--font-display); color: #fff; font-size: 1.15rem; display: flex; align-items: center; gap: 10px; margin: 0; }
.srch-drawer-head h3 i { color: var(--sg-gold); }
.srch-drawer-close {
  width: 36px; height: 36px; border-radius: 50%;
  background: rgba(255,255,255,0.05); border: 1px solid var(--border-subtle);
  color: var(--text-secondary); cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.9rem; transition: var(--transition);
}
.srch-drawer-close:hover { background: rgba(201,169,110,0.15); color: var(--sg-gold-light); transform: rotate(90deg); }
.srch-drawer-tabs {
  display: flex; gap: 4px; overflow-x: auto; padding: 12px 16px 8px;
  border-bottom: 1px solid var(--border-subtle); scrollbar-width: none;
}
.srch-drawer-tabs::-webkit-scrollbar { display: none; }
.srch-dtab {
  flex: 0 0 auto; padding: 8px 12px; background: transparent;
  border: 1px solid transparent; border-radius: 20px;
  color: var(--sg-text-3); font-size: 0.72rem; font-weight: 600;
  cursor: pointer; transition: var(--transition); font-family: var(--font-main);
  white-space: nowrap; display: inline-flex; align-items: center; gap: 5px;
}
.srch-dtab:hover { color: #fff; background: rgba(255,255,255,0.04); }
.srch-dtab.active { background: rgba(201,169,110,0.15); color: var(--sg-gold-light); border-color: rgba(201,169,110,0.3); }
.srch-drawer-body { flex: 1; overflow-y: auto; padding: 18px 22px 30px; }
.srch-drawer-body::-webkit-scrollbar { width: 5px; }
.srch-drawer-body::-webkit-scrollbar-thumb { background: rgba(201,169,110,0.3); border-radius: 4px; }
.srch-dpane { display: none; flex-direction: column; gap: 14px; }
.srch-dpane.active { display: flex; }
.srch-field { display: flex; flex-direction: column; gap: 6px; }
.srch-field > span { font-size: 0.7rem; text-transform: uppercase; letter-spacing: 1px; color: var(--sg-text-3); font-weight: 600; }
.srch-field input, .srch-field select {
  padding: 11px 14px; background: rgba(0,0,0,0.3);
  border: 1.5px solid var(--border-subtle); border-radius: 10px;
  color: #fff; font-family: var(--font-main); font-size: 0.85rem;
  outline: none; transition: var(--transition); width: 100%;
}
.srch-field input:focus, .srch-field select:focus { border-color: rgba(201,169,110,0.5); box-shadow: 0 0 0 3px rgba(201,169,110,0.1); }
.srch-field select option { background: #1a1a2e; color: #e0e0e0; }
.srch-field input[type="range"] { padding: 0; background: transparent; border: none; height: 6px; accent-color: var(--sg-gold); }

.srch-switch {
  display: flex; justify-content: space-between; align-items: center;
  padding: 11px 14px; background: rgba(255,255,255,0.02);
  border: 1px solid var(--border-subtle); border-radius: 10px;
  cursor: pointer; transition: var(--transition); font-size: 0.82rem;
  color: var(--text-primary); user-select: none;
}
.srch-switch:hover { background: rgba(255,255,255,0.04); }
.srch-switch input { position: absolute; opacity: 0; pointer-events: none; }
.srch-switch i {
  position: relative; width: 40px; height: 22px; background: rgba(255,255,255,0.1);
  border-radius: 20px; transition: background 0.3s ease; flex-shrink: 0; margin-left: 12px; display: inline-block;
}
.srch-switch i::after {
  content: ''; position: absolute; top: 2px; left: 2px; width: 18px; height: 18px;
  background: #e0e0e0; border-radius: 50%; transition: transform 0.3s ease, background 0.3s ease;
  box-shadow: 0 2px 6px rgba(0,0,0,0.3);
}
.srch-switch input:checked + i { background: var(--gold-gradient); }
.srch-switch input:checked + i::after { transform: translateX(18px); background: #1a1a2e; }
.srch-dns-info {
  font-size: 0.75rem; color: var(--sg-gold-light); background: rgba(201,169,110,0.08);
  border: 1px solid rgba(201,169,110,0.2); border-radius: 10px;
  padding: 10px 14px; text-align: center; line-height: 1.5;
}
.srch-export-row { display: flex; gap: 8px; }
.srch-export-row button { flex: 1; }

/* ─────────── SIDE PANEL ─────────── */
.sg-sidepanel {
  position: fixed; top: 0; right: 0; bottom: 0; z-index: 9995;
  width: 380px; max-width: 92vw; background: rgba(20,20,32,0.98);
  backdrop-filter: blur(24px); -webkit-backdrop-filter: blur(24px);
  border-left: 1px solid var(--border-subtle); transform: translateX(100%);
  transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex; flex-direction: column; box-shadow: -20px 0 60px rgba(0,0,0,0.5);
}
.sg-sidepanel.open { transform: translateX(0); }
.sg-sidepanel-overlay {
  position: fixed; inset: 0; z-index: 9994;
  background: rgba(0,0,0,0.5); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px);
}
.sg-sidepanel-header { display: flex; align-items: center; justify-content: space-between; padding: 16px; border-bottom: 1px solid var(--border-subtle); }
.sg-sidepanel-tabs { display: flex; gap: 4px; }
.sg-sp-tab {
  width: 40px; height: 40px; border-radius: 12px;
  background: transparent; border: 1px solid transparent;
  color: var(--text-secondary); cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.9rem; transition: var(--transition);
}
.sg-sp-tab:hover { background: rgba(255,255,255,0.06); color: #fff; }
.sg-sp-tab.active { background: linear-gradient(135deg, rgba(201,169,110,0.18), rgba(201,169,110,0.05)); border-color: rgba(201,169,110,0.35); color: var(--sg-gold); }
.sg-sidepanel-close {
  width: 36px; height: 36px; border-radius: 50%; background: rgba(255,255,255,0.06);
  border: 1px solid var(--border-subtle); color: var(--text-secondary);
  cursor: pointer; display: flex; align-items: center; justify-content: center;
  transition: var(--transition);
}
.sg-sidepanel-close:hover { background: rgba(255,65,108,0.15); color: var(--sg-danger-light); transform: rotate(90deg); }
.sg-sidepanel-body { flex: 1; overflow-y: auto; padding: 16px; }
.sg-sp-panel { display: none; }
.sg-sp-panel.active { display: block; animation: sgFadeIn 0.25s ease; }
.sg-sp-actions { display: flex; gap: 8px; margin-bottom: 14px; }
.sg-sp-search {
  flex: 1; padding: 10px 14px; background: rgba(0,0,0,0.3);
  border: 1px solid var(--border-subtle); border-radius: 10px;
  color: #fff; font-family: var(--font-main); font-size: 0.85rem; outline: none;
}
.sg-sp-search:focus { border-color: rgba(201,169,110,0.5); }
.sg-sp-clear, .sg-sp-add {
  width: 40px; height: 40px; border-radius: 10px;
  background: rgba(255,65,108,0.1); border: 1px solid rgba(255,65,108,0.25);
  color: var(--sg-danger-light); cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.85rem; flex-shrink: 0; transition: var(--transition);
}
.sg-sp-add { background: rgba(201,169,110,0.12); border-color: rgba(201,169,110,0.35); color: var(--sg-gold); }
.sg-sp-add:hover { background: rgba(201,169,110,0.22); transform: scale(1.05); }
.sg-sp-clear:hover { background: rgba(255,65,108,0.2); }
.sg-sp-list { display: flex; flex-direction: column; gap: 8px; }
.sg-sp-empty { text-align: center; padding: 40px 20px; color: var(--sg-text-3); font-size: 0.85rem; }
.sg-sp-empty i { font-size: 2rem; display: block; margin-bottom: 10px; opacity: 0.4; }
.sg-sp-item {
  display: flex; align-items: center; gap: 10px; padding: 10px 12px;
  border-radius: 12px; background: rgba(255,255,255,0.03);
  border: 1px solid var(--border-subtle); transition: var(--transition);
}
.sg-sp-item:hover { background: rgba(201,169,110,0.05); border-color: rgba(201,169,110,0.3); }
.sg-sp-item-icon {
  width: 32px; height: 32px; border-radius: 8px;
  background: rgba(201,169,110,0.12); color: var(--sg-gold);
  display: flex; align-items: center; justify-content: center;
  font-size: 0.8rem; flex-shrink: 0;
}
.sg-sp-item-body { flex: 1; min-width: 0; }
.sg-sp-item-title { color: #fff; font-size: 0.85rem; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; margin-bottom: 2px; }
.sg-sp-item-sub { color: var(--sg-text-3); font-size: 0.72rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-family: 'JetBrains Mono', monospace; }
.sg-sp-item-time { color: var(--sg-text-3); font-size: 0.68rem; white-space: nowrap; flex-shrink: 0; }
.sg-sp-item-del {
  width: 26px; height: 26px; border-radius: 50%; background: transparent;
  border: none; color: var(--sg-text-3); cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.7rem; flex-shrink: 0; transition: all 0.2s ease;
}
.sg-sp-item-del:hover { background: rgba(255,65,108,0.2); color: var(--sg-danger-light); }
.sg-dns-info { padding: 12px; background: rgba(79,172,254,0.06); border: 1px solid rgba(79,172,254,0.2); border-radius: 12px; margin-bottom: 14px; }
.sg-dns-note { color: #9bcdfa; font-size: 0.8rem; line-height: 1.55; margin: 0; }
.sg-dns-note i { color: var(--sg-info); margin-right: 4px; }
.sg-dns-result {
  padding: 10px 12px; background: rgba(0,0,0,0.3);
  border: 1px solid var(--border-subtle); border-radius: 10px;
  margin-top: 8px; font-family: 'JetBrains Mono', monospace;
  font-size: 0.75rem; color: var(--sg-ok); word-break: break-all; line-height: 1.6;
}

/* ─────────── MODAL ─────────── */
.sg-modal { position: fixed; inset: 0; z-index: 9990; display: none; align-items: center; justify-content: center; padding: 18px; }
.sg-modal.open { display: flex; animation: sgFadeIn 0.25s ease; }
.sg-modal-backdrop { position: absolute; inset: 0; background: rgba(0,0,0,0.7); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); }
.sg-modal-content {
  position: relative; z-index: 1; width: 100%; max-width: 560px;
  max-height: 90vh; overflow-y: auto;
  background: linear-gradient(160deg, rgba(20,15,35,0.98), rgba(45,15,45,0.98));
  border: 1px solid rgba(201,169,110,0.3); border-radius: 22px;
  box-shadow: 0 30px 80px rgba(0,0,0,0.7), 0 0 60px rgba(201,169,110,0.1);
  animation: sgPop 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.sg-modal-header { display: flex; align-items: center; justify-content: space-between; padding: 20px 22px; border-bottom: 1px solid var(--border-subtle); }
.sg-modal-header h3 { font-family: var(--font-display); color: #fff; font-size: 1.15rem; display: flex; align-items: center; gap: 10px; margin: 0; }
.sg-modal-header h3 i { color: var(--sg-gold); }
.sg-modal-close {
  width: 36px; height: 36px; border-radius: 50%; background: rgba(255,255,255,0.06);
  border: 1px solid var(--border-subtle); color: var(--text-secondary);
  cursor: pointer; display: flex; align-items: center; justify-content: center;
  transition: var(--transition);
}
.sg-modal-close:hover { background: rgba(255,65,108,0.15); color: var(--sg-danger-light); transform: rotate(90deg); }
.sg-modal-body { padding: 22px; }
.sg-modal-footer { display: flex; gap: 10px; padding: 16px 22px; border-top: 1px solid var(--border-subtle); justify-content: flex-end; }

/* ENGINE INFO BODY */
.sg-engine-info-row { display: flex; justify-content: space-between; padding: 10px 0; border-bottom: 1px dashed rgba(255,255,255,0.08); font-size: 0.85rem; }
.sg-engine-info-row:last-child { border-bottom: none; }
.sg-engine-info-row .label { color: var(--sg-text-3); }
.sg-engine-info-row .value { color: #fff; font-weight: 600; }
.sg-engine-rating { color: var(--sg-gold); }

/* SHORTCUT GRID */
.sg-shortcut-grid { display: flex; flex-direction: column; gap: 8px; }
.sg-shortcut-row { display: flex; align-items: center; gap: 10px; padding: 8px 12px; background: rgba(255,255,255,0.03); border: 1px solid var(--border-subtle); border-radius: 10px; }
.sg-shortcut-row kbd {
  background: rgba(255,255,255,0.08); border: 1px solid var(--border-subtle);
  border-bottom-width: 2px; border-radius: 6px; padding: 2px 7px;
  font-size: 0.72rem; font-family: 'JetBrains Mono', monospace;
  color: var(--sg-gold-light); font-weight: 600;
}
.sg-shortcut-row span:last-child { margin-left: auto; font-size: 0.82rem; color: var(--text-secondary); }

/* PRIVACY REPORT */
.sg-privacy-grade {
  text-align: center; padding: 20px;
  font-family: var(--font-display); font-size: 4rem; font-weight: 800;
  background: var(--gold-gradient); -webkit-background-clip: text; background-clip: text;
  color: transparent; line-height: 1;
}
.sg-privacy-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 12px; }
.sg-privacy-item { padding: 12px; background: rgba(255,255,255,0.03); border: 1px solid var(--border-subtle); border-radius: 10px; }
.sg-privacy-item .label { font-size: 0.72rem; color: var(--sg-text-3); text-transform: uppercase; letter-spacing: 0.5px; }
.sg-privacy-item .value { font-size: 1rem; color: #fff; font-weight: 700; margin-top: 4px; }

/* LOADING OVERLAY (BYPASS) */
.srch-loading-overlay {
  position: fixed; inset: 0; background: rgba(10,10,20,0.9);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  z-index: 10001; display: none; align-items: center; justify-content: center; padding: 20px;
}
.srch-loading-overlay.open { display: flex; animation: sgFadeIn 0.3s ease; }
.srch-loading-box { text-align: center; max-width: 360px; }
.srch-loading-spinner {
  width: 64px; height: 64px; border: 4px solid rgba(201,169,110,0.15);
  border-top-color: var(--sg-gold); border-radius: 50%; margin: 0 auto 20px;
  animation: sgSpin 0.9s linear infinite;
}
.srch-loading-box h3 { font-family: var(--font-display); color: #fff; font-size: 1.2rem; margin-bottom: 8px; }
.srch-loading-box p { color: var(--sg-text-3); font-size: 0.82rem; margin-bottom: 18px; }
.srch-progress-bar { width: 100%; height: 6px; background: rgba(255,255,255,0.08); border-radius: 6px; overflow: hidden; }
.srch-progress-fill {
  height: 100%; width: 0%; background: var(--gold-gradient);
  border-radius: 6px; transition: width 0.3s ease; box-shadow: 0 0 16px rgba(201,169,110,0.5);
}

/* SAFE MODE ACTIVE */
body.sg-safemode-active { box-shadow: inset 0 0 0 3px rgba(67,233,123,0.4); }
body.sg-no-anim * { animation: none !important; transition: none !important; }

/* LIGHT THEME OVERRIDES */
html[data-theme="light"] .srch-bar { background: rgba(255,255,255,0.85); border-color: rgba(0,0,0,0.1); }
html[data-theme="light"] .srch-input { color: #1a1a2e; }
html[data-theme="light"] .srch-input::placeholder { color: rgba(0,0,0,0.4); }
html[data-theme="light"] .srch-engine-select { background: rgba(0,0,0,0.05); color: #1a1a2e; }
html[data-theme="light"] .srch-engine-menu, html[data-theme="light"] .srch-suggest { background: rgba(255,255,255,0.98); border-color: rgba(0,0,0,0.08); }
html[data-theme="light"] .srch-engine-item, html[data-theme="light"] .srch-sug-item { color: #1a1a2e; }
html[data-theme="light"] .srch-result-panel, html[data-theme="light"] .srch-sec-dashboard,
html[data-theme="light"] .srch-bypass-panel, html[data-theme="light"] .srch-bm-panel,
html[data-theme="light"] .srch-info-card, html[data-theme="light"] .srch-tool-card { background: rgba(255,255,255,0.7); border-color: rgba(0,0,0,0.08); }
html[data-theme="light"] .srch-panel-title, html[data-theme="light"] .srch-tool-name,
html[data-theme="light"] .srch-res-title, html[data-theme="light"] .srch-info-card h3 { color: #1a1a2e; }
html[data-theme="light"] .srch-input-flat { background: rgba(0,0,0,0.03); color: #1a1a2e; }
html[data-theme="light"] .srch-drawer { background: rgba(255,255,255,0.98); border-left-color: rgba(0,0,0,0.1); }
html[data-theme="light"] .srch-drawer-head h3 { color: #1a1a2e; }
html[data-theme="light"] .srch-field > span { color: #666; }
html[data-theme="light"] .srch-field input, html[data-theme="light"] .srch-field select { background: rgba(0,0,0,0.03); color: #1a1a2e; border-color: rgba(0,0,0,0.1); }
html[data-theme="light"] .srch-switch { color: #1a1a2e; background: rgba(0,0,0,0.02); }
html[data-theme="light"] .sg-modal-content { background: rgba(255,255,255,0.98); }
html[data-theme="light"] .sg-modal-header h3 { color: #1a1a2e; }
html[data-theme="light"] .sg-browser-bar { background: rgba(255,255,255,0.9); }
html[data-theme="light"] .sg-mini-searchbar { background: rgba(0,0,0,0.05); }
html[data-theme="light"] .sg-mini-searchbar-input { color: #1a1a2e; }
html[data-theme="light"] .sg-tab { color: #4a4a5e; }
html[data-theme="light"] .sg-tab.active { color: #1a1a2e; }
html[data-theme="light"] .sg-sidepanel { background: rgba(255,255,255,0.98); }
html[data-theme="light"] .sg-home-section-title { color: #1a1a2e; }

/* ─────────── ANIMATIONS ─────────── */
@keyframes sgHeroFloat { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
@keyframes sgFloat { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
@keyframes sgPulse { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.1); } }
@keyframes sgSpin { to { transform: rotate(360deg); } }
@keyframes sgShine { to { background-position: 200% center; } }
@keyframes sgFadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes sgFadeUp { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: translateY(0); } }
@keyframes sgFadeDown { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: translateY(0); } }
@keyframes sgPop { from { opacity: 0; transform: scale(0.94) translateY(20px); } to { opacity: 1; transform: scale(1) translateY(0); } }
@keyframes sgShimmer { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }
@keyframes sgDotPulse { 0%, 100% { transform: scale(0.9); opacity: 0.7; } 50% { transform: scale(1.15); opacity: 1; } }
@keyframes sgShake {
  0%, 100% { transform: translateX(0); }
  10%, 30%, 50%, 70%, 90% { transform: translateX(-4px); }
  20%, 40%, 60%, 80% { transform: translateX(4px); }
}

/* ─────────── A11Y ─────────── */
:focus-visible { outline: 2px solid var(--sg-gold); outline-offset: 3px; border-radius: 4px; }
button:focus-visible { outline-offset: 2px; }

/* ─────────── RESPONSIVE ─────────── */
@media (max-width: 1024px) {
  .srch-sec-grid { grid-template-columns: 180px 1fr; gap: 16px; }
  .srch-score-svg { max-width: 160px; }
}
@media (max-width: 768px) {
  .sg-home-title { font-size: 1.8rem; }
  .sg-home-logo { width: 76px; height: 76px; font-size: 2rem; }
  .srch-bar { flex-wrap: wrap; padding: 8px; border-radius: 16px; }
  .srch-engine-select { width: 100%; justify-content: space-between; }
  .srch-engine-menu { left: 0; right: 0; min-width: unset; }
  .srch-input { width: 100%; flex: 1 0 100%; order: 5; padding: 10px 8px; }
  .srch-bar-search-icon { display: none; }
  .srch-go-btn { flex: 1; justify-content: center; order: 6; }
  .srch-mini-btn { order: 3; }
  .srch-mini-clear { order: 4; }
  .srch-sec-grid { grid-template-columns: 1fr; }
  .srch-sec-score-wrap { width: 150px; height: 150px; }
  .srch-toolbar { grid-template-columns: 1fr 1fr; }
  .srch-info-cards { grid-template-columns: 1fr; }
  .srch-bypass-input-row { flex-direction: column; }
  .srch-drawer { width: 100%; max-width: 100%; }
  .sg-browser-bar { flex-wrap: wrap; border-radius: 20px; padding: 8px; gap: 6px; }
  .sg-browser-bar-left, .sg-browser-bar-right { gap: 2px; }
  .sg-mini-searchbar { order: 3; flex-basis: 100%; margin-top: 6px; }
  .sg-viewport, .sg-frame { min-height: 460px; }
  .sg-sidepanel { width: 100%; max-width: 100%; }
  .sg-quicklinks-grid { grid-template-columns: repeat(4, 1fr); }
  .sg-find-bar input { width: 120px; }
}
@media (max-width: 480px) {
  .sg-container { padding: 0 0.75rem 6rem; }
  .sg-home-title { font-size: 1.5rem; }
  .sg-home-sub { font-size: 0.88rem; }
  .sg-home-logo { width: 64px; height: 64px; font-size: 1.7rem; }
  .sg-pill { font-size: 0.72rem; padding: 5px 10px; }
  .srch-qtag { font-size: 0.72rem; padding: 6px 12px; }
  .srch-toolbar { grid-template-columns: 1fr; }
  .srch-go-btn { padding: 10px 16px; font-size: 0.85rem; }
  .srch-go-btn span { display: none; }
  .srch-go-btn::after { content: 'Cari'; }
  .srch-sec-actions { flex-direction: column; }
  .srch-sec-actions button { width: 100%; }
  .srch-log { max-height: 160px; font-size: 0.7rem; }
  .srch-drawer-body { padding: 14px 16px 24px; }
  .srch-drawer-head { padding: 16px 16px 12px; }
  .srch-panel-title { font-size: 1.05rem; }
  .sg-quicklinks-grid { grid-template-columns: repeat(3, 1fr); }
  .sg-quicklink { padding: 12px 4px; font-size: 0.72rem; }
  .sg-ql-icon { width: 32px; height: 32px; font-size: 0.9rem; }
  .sg-blocked-actions { flex-direction: column; }
  .sg-blocked-actions .sg-btn { width: 100%; justify-content: center; }
  .sg-privacy-grid { grid-template-columns: 1fr; }
  .srch-export-row { flex-direction: column; }
}
@media (max-width: 360px) {
  .sg-home-title { font-size: 1.3rem; }
  .srch-tool-card { padding: 11px 12px; gap: 10px; }
  .srch-tool-icon { width: 34px; height: 34px; font-size: 0.9rem; }
  .srch-tool-name { font-size: 0.78rem; }
  .srch-score-num { font-size: 1.9rem; }
  .srch-sec-score-wrap { width: 130px; height: 130px; }
}

/* ─────────── REDUCED MOTION ─────────── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* ─────────── HIGH CONTRAST ─────────── */
@media (prefers-contrast: more) {
  :root {
    --sg-border: rgba(255,255,255,0.2);
    --sg-text-2: #ddd;
    --sg-text-3: #bbb;
  }
}

/* ─────────── PRINT ─────────── */
@media print {
  header, footer, .sg-browser-bar, .sg-tabsbar, .srch-toolbar, .sg-sidepanel,
  .srch-drawer, .sg-sidepanel-overlay, .srch-drawer-overlay, .back-to-top { display: none !important; }
  body { background: #fff !important; color: #000 !important; }
  .sg-frame { border: none; }
}