/* PollyVox v0.70 — universal search, search results and discovery polish. */
body.pv-search-open { overflow: hidden; }

.pv-search-toggle { display: inline-flex; align-items: center; gap: 7px; }
.pv-search-toggle__shortcut { display: inline-flex; align-items: center; justify-content: center; min-width: 32px; height: 22px; padding: 0 6px; border: 1px solid color-mix(in srgb, currentColor 22%, transparent); border-radius: 7px; font-size: .68rem; font-weight: 800; line-height: 1; opacity: .68; }

.pv-search-dialog { position: fixed; inset: 0; z-index: 100000; display: none; padding: clamp(18px, 6vh, 70px) 18px 18px; }
.pv-search-dialog.is-open { display: block; }
.pv-search-dialog__scrim { position: absolute; inset: 0; width: 100%; height: 100%; padding: 0; border: 0; background: rgba(7, 10, 20, .74); backdrop-filter: blur(8px); cursor: default; }
.pv-search-dialog__panel { position: relative; width: min(var(--pv-search-width), calc(100vw - 36px)); max-height: min(860px, calc(100vh - clamp(36px, 12vh, 140px))); margin: 0 auto; overflow: hidden; display: grid; grid-template-rows: auto auto auto minmax(0, 1fr) auto; background: #fff; color: #111827; border: 1px solid rgba(255,255,255,.55); border-radius: 24px; box-shadow: 0 34px 90px rgba(0,0,0,.34); animation: pv70-search-in .18s ease-out both; }
@keyframes pv70-search-in { from { opacity: 0; transform: translateY(-12px) scale(.985); } to { opacity: 1; transform: translateY(0) scale(1); } }
.pv-search-dialog__head { display: flex; justify-content: space-between; gap: 24px; align-items: flex-start; padding: 24px 26px 16px; }
.pv-search-dialog__eyebrow { display: block; margin-bottom: 5px; color: var(--pv-accent); font-size: .72rem; font-weight: 850; letter-spacing: .09em; text-transform: uppercase; }
.pv-search-dialog__head h2 { margin: 0; max-width: 700px; font-size: clamp(1.15rem, 2vw, 1.7rem); line-height: 1.18; }
.pv-search-dialog__close { flex: 0 0 38px; width: 38px; height: 38px; display: grid; place-items: center; border: 1px solid #dfe3eb; border-radius: 50%; background: #fff; color: #111827; cursor: pointer; }
.pv-search-dialog__close:hover, .pv-search-dialog__close:focus-visible { border-color: var(--pv-accent); color: var(--pv-accent); }
.pv-search-dialog__close svg { width: 19px; height: 19px; }
.pv-search-dialog__form { padding: 0 26px 18px; }
.pv-search-dialog .pv-searchform { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px; }
.pv-search-dialog .pv-searchform input[type="search"] { min-width: 0; height: 54px; padding: 0 18px; border: 2px solid #111827; border-radius: 14px; background: #fff; color: #111827; font-size: 1rem; outline: none; }
.pv-search-dialog .pv-searchform input[type="search"]:focus { border-color: var(--pv-accent); box-shadow: 0 0 0 4px color-mix(in srgb, var(--pv-accent) 14%, transparent); }
.pv-search-dialog .pv-searchform button { min-height: 54px; padding: 0 22px; border: 0; border-radius: 14px; background: #111827; color: #fff; font-weight: 850; cursor: pointer; }
.pv-search-dialog .pv-searchform button:hover, .pv-search-dialog .pv-searchform button:focus-visible { background: var(--pv-accent); }

.pv-command-results { min-height: 150px; overflow: auto; overscroll-behavior: contain; border-top: 1px solid #e7e9ef; }
.pv-command-results.is-start { padding: 20px 26px 26px; }
.pv-command-start + .pv-command-start { margin-top: 22px; }
.pv-command-start h3, .pv-command-group header h3 { margin: 0; font-size: .76rem; letter-spacing: .08em; text-transform: uppercase; color: #697080; }
.pv-command-chips { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 11px; }
.pv-command-chips button { border: 1px solid #d8dce5; border-radius: 999px; padding: 8px 13px; background: #f8f9fb; color: #111827; font-size: .83rem; font-weight: 750; cursor: pointer; }
.pv-command-chips button:hover, .pv-command-chips button:focus-visible { border-color: var(--pv-accent); background: color-mix(in srgb, var(--pv-accent) 8%, #fff); color: var(--pv-accent); }
.pv-command-message { min-height: 170px; display: grid; place-items: center; padding: 30px; color: #697080; text-align: center; }
.pv-command-results.is-loading .pv-command-message::before { content: ""; width: 22px; height: 22px; margin-right: 10px; border: 2px solid #d8dce5; border-top-color: var(--pv-accent); border-radius: 50%; animation: pv70-spin .7s linear infinite; }
@keyframes pv70-spin { to { transform: rotate(360deg); } }
.pv-command-groups { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; gap: 0; }
.pv-command-group { min-width: 0; padding: 18px 20px 20px; border-bottom: 1px solid #e7e9ef; }
.pv-command-group:nth-child(odd) { border-right: 1px solid #e7e9ef; }
.pv-command-group header { display: flex; justify-content: space-between; gap: 12px; align-items: center; margin-bottom: 10px; }
.pv-command-group header span { display: grid; place-items: center; min-width: 24px; height: 24px; padding: 0 7px; border-radius: 999px; background: #f0f2f6; color: #697080; font-size: .72rem; font-weight: 800; }
.pv-command-group__items { display: grid; gap: 4px; }
.pv-command-item { display: grid; grid-template-columns: 66px minmax(0, 1fr) 18px; gap: 11px; align-items: center; min-width: 0; padding: 8px; border-radius: 12px; color: #111827; text-decoration: none; }
.pv-command-item:hover, .pv-command-item:focus-visible, .pv-command-item.is-active { background: #f2f4f8; outline: none; }
.pv-command-item.is-active { box-shadow: inset 3px 0 0 var(--pv-accent); }
.pv-command-item__media { width: 66px; aspect-ratio: 16 / 10; overflow: hidden; border-radius: 9px; background: #eef0f4; }
.pv-command-item__media img { width: 100%; height: 100%; display: block; object-fit: cover; }
.pv-command-item__body { min-width: 0; }
.pv-command-item__body strong { display: block; overflow: hidden; color: #111827; font-size: .88rem; line-height: 1.28; text-overflow: ellipsis; white-space: nowrap; }
.pv-command-item__body small { display: flex; min-width: 0; gap: 7px; align-items: center; margin-top: 4px; color: #717887; font-size: .7rem; }
.pv-command-item__body small b { flex: 0 0 auto; color: var(--pv-accent); font-weight: 800; }
.pv-command-item__body small span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pv-command-item > svg { width: 16px; height: 16px; color: #9ba1ad; }
.pv-command-all { display: flex; justify-content: space-between; align-items: center; gap: 18px; padding: 15px 26px; color: #111827; font-weight: 850; text-decoration: none; background: #fafbfc; }
.pv-command-all:hover, .pv-command-all:focus-visible { color: var(--pv-accent); }
.pv-search-dialog__foot { display: flex; flex-wrap: wrap; gap: 18px; padding: 12px 26px; border-top: 1px solid #e7e9ef; color: #767d8a; font-size: .7rem; }
.pv-search-dialog__foot span { display: inline-flex; align-items: center; gap: 5px; }
.pv-search-dialog__foot kbd { min-width: 22px; padding: 3px 5px; border: 1px solid #d8dce5; border-bottom-width: 2px; border-radius: 5px; background: #fff; color: #343945; font: inherit; font-weight: 800; text-align: center; }

/* Search result page. */
.pv-search-page .pv-layout__main--archive { display: block; }
.pv-search-page__head { display: grid; gap: 14px; }
.pv-search-page__head .pv-searchform { max-width: 720px; }
.pv-search-toolbar { display: flex; justify-content: space-between; gap: 20px; align-items: center; margin: 20px 0 24px; }
.pv-search-filters { display: flex; flex-wrap: wrap; gap: 8px; }
.pv-search-filters a { padding: 7px 12px; border: 1px solid #d8dce5; border-radius: 999px; color: #343945; font-size: .78rem; font-weight: 800; text-decoration: none; }
.pv-search-filters a:hover, .pv-search-filters a:focus-visible, .pv-search-filters a.is-active { border-color: #111827; background: #111827; color: #fff; }
.pv-search-sort { display: flex; align-items: center; gap: 9px; flex: 0 0 auto; }
.pv-search-sort label { color: #697080; font-size: .76rem; font-weight: 750; }
.pv-search-sort select { min-height: 38px; border: 1px solid #d8dce5; border-radius: 10px; background: #fff; padding: 0 34px 0 11px; color: #111827; font-weight: 700; }
.pv-search-count { margin: 0 0 14px; color: #697080; font-size: .82rem; }
.pv-search-results { display: grid; gap: var(--pv-archive-row-gap, 18px); }
.pv-search-results .pv-archive-card { width: 100%; }

@media (max-width: 760px) {
	.pv-search-toggle__shortcut { display: none; }
	.pv-search-dialog { padding: 0; }
	.pv-search-dialog__panel { width: 100%; max-height: 100vh; height: 100%; border-radius: 0; }
	.pv-search-dialog__head { padding: 18px 17px 13px; }
	.pv-search-dialog__form { padding: 0 17px 14px; }
	.pv-search-dialog .pv-searchform { grid-template-columns: minmax(0, 1fr); }
	.pv-search-dialog .pv-searchform button { display: none; }
	.pv-command-groups { grid-template-columns: minmax(0, 1fr); }
	.pv-command-group:nth-child(odd) { border-right: 0; }
	.pv-command-results.is-start { padding: 18px 17px 22px; }
	.pv-search-dialog__foot { padding-inline: 17px; }
	.pv-search-toolbar { align-items: flex-start; flex-direction: column; }
	.pv-search-sort { width: 100%; justify-content: space-between; }
}

@media (prefers-reduced-motion: reduce) {
	.pv-search-dialog__panel { animation: none; }
}
