/* AISearch Global — AI Visibility Console
   Console-only overrides for ai-toolkit.html. Loaded AFTER toolkit.css so it can
   win on source order without !important. Nothing here touches toolkit.css itself,
   so the 8 individual tool pages that share it are unaffected — this page alone
   gets the rounded "calculator device" look and a flat jet-black background. */

body {
  background: var(--black);
}

[hidden] { display: none !important; }

/* Clean, sharp-edged surfaces — matches the site's editorial look everywhere
   else (border-radius: 0 in toolkit.css). No rounded corners on this page. */

/* ── CONSOLE SCREEN ── */
.console-screen {
  background: color-mix(in srgb, var(--tiffany) 8%, var(--charcoal));
  border: 1px solid rgba(10,186,181,.25);
  box-shadow: inset 0 2px 12px rgba(0,0,0,.5), 0 20px 50px rgba(0,0,0,.35);
  padding: 24px;
  margin-bottom: 28px;
}
.screen-tabs { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 18px; }
.screen-tab {
  background: rgba(255,255,255,.03); border: 1px solid var(--border); color: var(--silver);
  font-family: var(--fb); font-size: .84rem; font-weight: 600; padding: 9px 16px; cursor: pointer;
  transition: background .15s, border-color .15s, color .15s;
}
.screen-tab:hover { border-color: rgba(10,186,181,.4); color: var(--white); }
.screen-tab.active { background: var(--tiffany); color: var(--black); border-color: var(--tiffany); }

.screen-panel { display: none; }
.screen-panel.active { display: block; animation: fadeUp .3s ease; }
.screen-copy { font-size: .9rem; color: var(--silver); line-height: 1.7; margin-bottom: 10px; }
.screen-steps { margin: 0; padding-left: 1.2rem; color: var(--silver); font-size: .9rem; line-height: 1.85; }
.screen-steps strong { color: var(--white); }
.screen-steps em { color: var(--tiffany); font-style: normal; }

.screen-btn {
  display: inline-flex; align-items: center; gap: 8px; background: var(--tiffany); color: var(--black);
  font-family: var(--fh); font-size: .88rem; font-weight: 700; padding: 11px 20px; border: none; cursor: pointer;
  transition: opacity .15s;
}
.screen-btn:hover { opacity: .88; }

/* ── WALKTHROUGH ── */
.walkthrough-dim { opacity: .28; filter: saturate(.5); transition: opacity .25s, filter .25s; }
.walkthrough-active {
  position: relative; z-index: 5; transform: translateY(-2px);
  box-shadow: 0 0 0 2px var(--tiffany), 0 20px 44px rgba(10,186,181,.35) !important;
  transition: box-shadow .25s, transform .25s;
}

/* Floating guide — fixed to the viewport (not the scrolling page) so it's
   always reachable while the tour scrolls each card into view. */
.walkthrough-popup {
  position: fixed; top: 20px; left: 20px; /* JS repositions this next to the active card on every step, scroll and resize */
  z-index: 200; width: min(340px, calc(100vw - 32px));
  background: color-mix(in srgb, var(--tiffany) 16%, var(--charcoal));
  border: 1px solid var(--tiffany);
  box-shadow: 0 16px 40px rgba(0,0,0,.55), 0 0 0 1px rgba(10,186,181,.25);
  padding: 16px 18px;
  transition: top .18s ease, left .18s ease;
}
.walkthrough-popup::before {
  content: ""; position: absolute; width: 14px; height: 14px;
  background: inherit; border: inherit; border-right: none; border-bottom: none;
  transform: rotate(45deg); z-index: -1;
}
.walkthrough-popup[data-arrow="top"]::before { top: -8px; left: var(--wt-arrow-x, 24px); }
.walkthrough-popup[data-arrow="bottom"]::before { bottom: -8px; left: var(--wt-arrow-x, 24px); border-right: inherit; border-bottom: inherit; border-top: none; border-left: none; }
.wt-popup-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.wt-popup-step { font-family: var(--fm); font-size: .6rem; color: var(--tiffany); text-transform: uppercase; letter-spacing: .1em; }
.wt-popup-close {
  background: none; border: none; color: var(--muted); font-family: var(--fb); font-size: .74rem;
  cursor: pointer; padding: 2px 4px; transition: color .15s;
}
.wt-popup-close:hover { color: var(--white); }
.wt-popup-title { font-family: var(--fh); font-size: 1.05rem; font-weight: 700; color: var(--white); margin-bottom: 6px; }
.wt-popup-desc { font-size: .86rem; color: var(--silver); line-height: 1.55; margin-bottom: 16px; }
.wt-popup-nav { display: flex; gap: 10px; }
.wt-popup-nav button {
  flex: 1; display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  font-family: var(--fb); font-size: .84rem; font-weight: 600; padding: 9px 14px; cursor: pointer;
  transition: opacity .15s, background .15s, border-color .15s;
}
#wtPopupBack { background: none; border: 1px solid rgba(255,255,255,.18); color: var(--silver); }
#wtPopupBack:hover:not(:disabled) { border-color: var(--silver); color: var(--white); }
#wtPopupBack:disabled { opacity: .35; cursor: not-allowed; }
#wtPopupNext { background: var(--tiffany); border: none; color: var(--black); }
#wtPopupNext:hover { opacity: .88; }

@media (max-width: 560px) {
  /* Precise per-card pinning gets cramped on small screens — pin to the
     bottom instead, same as the old behaviour, still always reachable. */
  .walkthrough-popup.mobile-pinned { top: auto !important; bottom: 16px; left: 16px !important; right: 16px; width: auto; }
  .walkthrough-popup.mobile-pinned::before { display: none; }
}

/* ── RESULTS ACTIONS (mailto / share link) ── */
.hub-results-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 18px; }
.hub-results-actions .screen-btn.secondary {
  background: none; color: var(--tiffany); border: 1px solid rgba(10,186,181,.4);
}
.hub-results-actions .screen-btn.secondary:disabled { opacity: .45; cursor: not-allowed; }
.hub-results-back {
  display: inline-flex; align-items: center; gap: 6px; margin-bottom: 14px;
  font-family: var(--fb); font-size: .82rem; color: var(--muted); background: none; border: none; cursor: pointer;
}
.hub-results-back:hover { color: var(--tiffany); }

@media (max-width: 560px) {
  .console-screen { padding: 18px 16px; }
  .walkthrough-nav #wtSkip { margin-left: 0; }
}
