/* The website's copy of the search page (web/search/shell.js, scripts/build-site.mjs), on top of the
   extension's tokens.css and search.css. */

/* Read only: what changes the history, and what's only in the extension, isn't here */
body.web .act[data-act="collect"],
body.web .mode-acts,
body.web .menu-new,
body.web #pic-btn,
body.web .side-nav li:has(#stats),
body.web .side-nav li:has(#settings),
body.web .side-foot,
body.web #plan-banner,
body.web #open-tab { display: none !important; }

/* Signed in but not unlocked yet (or signed out): only the bar, nothing of the history or its tools */
body.web-locked #timeline,
body.web-locked #glance,
body.web-locked #memories,
body.web-locked #modebar,
body.web-locked #status,
body.web-locked .topbar .search,
body.web-locked .topbar .filters,
body.web-locked .topbar .count,
body.web-locked .side-coll { display: none !important; }

/* Whose history this is, and signing in and out */
.webbar { margin: 12px 24px 0; padding: 12px 16px; display: flex; align-items: center; gap: 12px 16px; flex-wrap: wrap;
  background: var(--panel); border: 1px solid var(--line); border-radius: 10px; }
.webbar[hidden] { display: none; }
.webbar-text { flex: 1 1 320px; margin: 0; font-size: 14px; color: var(--muted); }
.webbar-note { display: block; margin-top: 4px; color: var(--orange-text); }
.webbar-acts { display: flex; gap: 8px; flex-wrap: wrap; }
.webbar-acts:empty { display: none; }
.webbar-acts .btn { padding: 9px 14px; font-size: 14px; }
.webbar-acts .btn:disabled { opacity: .5; cursor: not-allowed; }
.webbar-progress { flex: 1 0 100%; height: 4px; border-radius: 2px; background: var(--line-2); overflow: hidden; }
.webbar-progress[hidden] { display: none; }
.webbar-progress i { display: block; height: 100%; width: 0; background: var(--accent-mark); transition: width .3s; }

/* The passphrase */
.unlock { width: calc(100% - 32px); max-width: 420px; padding: 24px; border: 1px solid var(--line-2); border-radius: 12px;
  background: var(--panel); color: var(--text); box-shadow: var(--shadow-dialog); }
.unlock::backdrop { background: var(--scrim); }
.unlock h2 { margin: 0 0 8px; font-size: 20px; }
.unlock p { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.5; }
.unlock .field { display: grid; gap: 6px; margin: 18px 0 10px; font-size: 14px; }
.unlock input { padding: 10px 12px; border: 1px solid var(--line-2); border-radius: 8px; background: var(--panel-2); color: var(--text); font: inherit; }
.unlock input:focus { outline: 2px solid var(--accent-text); outline-offset: 1px; }
.unlock .unlock-note { min-height: 1.5em; margin-bottom: 14px; color: var(--danger); }
.unlock .row { display: flex; gap: 8px; }

/* Signing in to the account (the same dialog, before the passphrase): a code by email, or a provider */
.unlock .field[hidden] { display: none; }
.unlock p a { color: var(--accent-text); }
.unlock .unlock-note.ok { color: var(--muted); } /* "A code is on its way", not an error */
.signin-or { display: flex; align-items: center; gap: 10px; margin: 20px 0 12px; font-size: 13px; color: var(--dim); }
.signin-or::before, .signin-or::after { content: ''; flex: 1; height: 1px; background: var(--line); }
.unlock .providers { flex-direction: column; }
.unlock .providers .btn { width: 100%; }
.unlock .providers[hidden], .unlock .providers .btn[hidden], .signin-or[hidden] { display: none; }

/* Inside the home page (?embed=1): the demo and its search, without the menu or the bar */
body.embed .d-drawer-side,
body.embed .nav-open,
body.embed .top-logo,
body.embed .webbar { display: none !important; }
