/* src/assets/css/finder.css */
.pf { --gap: 1rem; }
.pf__toolbar { position: sticky; top: 0; background: #fff; padding: var(--gap); z-index: 10; border-bottom: 1px solid #eee; }
.pf__form { display: flex; gap: .75rem; align-items: center; flex-wrap: wrap; }
.pf__types label { margin-right: .5rem; color: #6d282b; font-size: 18px; }
.pf__layout { display: grid; grid-template-columns: 380px 1fr; gap: var(--gap); padding: var(--gap); }
.pf__filters { border-right: 1px solid #eee; padding-right: var(--gap); }
.pf__filters-head { display:flex; align-items:center; justify-content:space-between; margin-bottom: .5rem; }
.pf__grid { min-height: 200px; }
.pf__title { font-size: 1rem; line-height: 1.2; margin:.25rem 0 .25rem; }
.pf__updated { display:block; font-size:.8rem; color:#666; margin-bottom:.35rem; }
.pf__caption { margin:0; color:#333; font-size:.9rem; }
.pf__empty { opacity:.7; padding: 1rem; }
.pf__more { display:flex; justify-content:center; padding: 1rem 0; }

/* Results: list rows */
.pf .pf__results .pf__list { list-style-type:none; margin:0; padding:0; display:block; }
.pf__li   { margin:0; padding:0; }

.pf__row {
  display:grid;
  grid-template-columns: 80px 1fr;       /* thumb | body */
  gap: .85rem;
  align-items:center;
  padding: .65rem .75rem;
  border-bottom: 1px solid #eee;
  text-decoration:none;
  color: inherit;
  min-height: 88px;                      /* consistent row height */
}

.pf__row.is-clickable { cursor:pointer; }
.pf__row.is-clickable:focus,
.pf__row.is-clickable:hover { background:#fafafa; outline: 2px solid transparent; }
.pf__row.is-static { cursor:default; }

.pf__thumbbox { width:80px; height:80px; border-radius:6px; overflow:hidden; background:#f3f3f3; display:flex; align-items:center; justify-content:center; }
.pf__thumbbox img { width:100%; height:100%; object-fit:cover; display:block; }
.pf__thumbbox--placeholder { width:100%; height:100%; background: repeating-linear-gradient(45deg,#eee,#eee 10px,#f6f6f6 10px,#f6f6f6 20px); }

.pf__body { min-width:0; }
.pf__topline { display:flex; gap:.5rem; align-items:center; margin-bottom:.25rem; }
.pf__badge { font-size:.72rem; padding:.12rem .45rem; border-radius:999px; border:1px solid #ddd; }
.pf__badge--story { border-color:#3b82f6; color:#1854c4; }
.pf__badge--asset { color:#444; }
.pf__badge--asset-type { border-color:#7cda24; color:#7cda24; }

.pf__updated { margin-left:auto; font-size:.8rem; color:#666; }

.pf__title { margin:0 0 .2rem; font-size:1rem; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.pf__caption { margin:0; color:#333; font-size:.9rem; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }

/* mobile only */
@media (max-width: 980px) {
  .pf__layout { position: relative; grid-template-columns: 1fr; }

  /* make the drawer live INSIDE the layout */
  .pf__filters {
    position: absolute;      /* not fixed */
    top: 0; left: 0; bottom: 0; width: 100%;
    background: #fff;
    transform: translateX(-115%);
    transition: transform .25s ease;
    padding: 1rem;
    overflow-y: auto;        /* scroll if tall */
    z-index: 2;              /* above results, below global header */
  }
  .pf__filters.pf--open { transform: translateX(0); }

  .pf__row { padding:.6rem .65rem; }
  
	.pf input[type="search"]#pf-q {
		width: 100%;
	}
  
}

@media (min-width: 981px) {

	.pf button#pf-open-filters {
		display: none;		
	}
	
	.pf input[type="search"]#pf-q {
		width: 40%;
	}
	
}

.pf input[type="search"] {
	padding: 0 8px;
	line-height: 2;
	min-height: 30px;
	border: 1px solid #2c3338;
	border-radius: 4px;
}

.pf input[type="search"]:focus {
	border-color: #2271b1;
}

.pf .pataka-tax__desc {
	font-size: 13px;
	line-height: 1.4em;
}

.pf button {
	color: #2271b1;
	min-height: 30px;
	border-radius: 3px;
	border: 1px solid #2c3338;
	min-width: 80px;
}

.pf button:focus {
	border-color: #2271b1;
}

/* Busy cursor when loading */
.pf.is-loading, .pf.is-loading * { cursor: progress !important; }

/* Loader overlay that covers only the results area */
.pf__results { position: relative; overflow: hidden; }
.pf__loading[hidden] { display: none !important; }
.pf__loading {
  position: absolute; inset: 0;
  display: grid; place-items: center;
  background: rgba(255,255,255,.65);
  z-index: 3;
}

/* Simple CSS spinner */
.pf__spinner {
  width: 36px; height: 36px;
  border: 3px solid rgba(0,0,0,.15);
  border-top-color: rgba(0,0,0,.55);
  border-radius: 50%;
  animation: pfspin .9s linear infinite;
}
@keyframes pfspin { to { transform: rotate(360deg); } }

/* copy and paste from admin screen .. some of this is not necessary */
/* Split layout */
.pman-root{margin:0 0 12px;max-width:unset}
.pman-split{display:grid;grid-template-columns: 320px 8px minmax(400px,1fr);gap:0;height:calc(100vh - 150px);background:#fff;border:1px solid #ccd0d4;border-radius:8px;overflow:hidden}
.pman-left{min-width:220px;max-width:560px;overflow:auto;padding:12px}
.pman-right{overflow:auto;padding:12px;border-left:1px solid #ececec}
.pman-gutter{cursor:col-resize;background:#f3f4f5;border-left:1px solid #e5e5e5;border-right:1px solid #e5e5e5}
.pman-gutter:hover{background:#eceff2}
.pman-muted{color:#646970}
.pman-inline{display:flex;align-items:center;gap:8px;justify-content:space-between;margin-bottom:8px}
.pman-inline .left{display:flex;align-items:center;gap:8px}
.pman-inline .right{display:flex;align-items:center;gap:8px}
.pman-search-row{display:flex;gap:8px;margin:8px 0 12px}
.pman-search-row input[type="search"]{width:100%}
/* Filters form bits */
.pman-field{display:flex;align-items:center;gap:6px;margin:6px 0}
/* Results table */
.pman-table{width:100%;border-collapse:collapse}
.pman-table th,.pman-table td{border-bottom:1px solid #e2e4e7;padding:8px 10px;vertical-align:top}
.pman-table th{background:#f6f7f7;text-align:left;font-weight:600;position:sticky;top:0}
.pman-pill{display:inline-block;padding:2px 8px;border:1px solid #c3c4c7;border-radius:999px;font-size:12px}
.pman-row-actions{margin-top:4px;font-size:12px}
.pman-row-actions a{margin-right:8px}
.pman-pager{display:flex;gap:8px;align-items:center;justify-content:flex-end;margin:8px 0}
.pman-status{margin-left:8px}
/* copy toast (scoped) */
.pman-copy-toast{margin-left:6px;color:#0073aa}
/* Make right pane anchor for overlay */
#pman_right{ position:relative }
/* Busy overlay */
.pman-busy {position: absolute; inset: 0; display: none; background: rgba(255,255,255,.6); gap: 10px; align-items: center; justify-content: center; z-index: 10;}
/* Spinner */
.pman-spinner{width:18px; height:18px; border:2px solid #2271b1; border-right-color:transparent;border-radius:50%; animation:pman-spin .8s linear infinite;}
@keyframes pman-spin{ to{ transform:rotate(360deg) } }

/* Dim table while loading */
.pman-right.is-loading #pman_table{ opacity:.55; }

/* Only visible while loading */
#pman_right.is-loading .pman-busy { display: flex; }

/* Skeleton rows */
.pman-skel .sk{display:inline-block; height:12px; border-radius:6px; width:100%;background:linear-gradient(90deg,#eee 25%,#f5f5f5 37%,#eee 63%);background-size:400% 100%; animation:pman-shimmer 1.2s ease-in-out infinite;}
@keyframes pman-shimmer{ 0%{background-position:100% 0} 100%{background-position:0 0} }
.pman-pager{display:flex;gap:8px;align-items:center;justify-content:space-between;margin:8px 0}
.pman-pager .left{display:flex;align-items:center;gap:8px}
.pman-pager .right{display:flex;align-items:center;gap:8px}

/* === Links-related === */
/* chips */
.pman-chip{display:inline-flex;align-items:center;gap:6px;font-size:12px;border:1px solid #c3c4c7;border-radius:999px;padding:2px 8px;cursor:pointer;user-select:none}
.pman-chip:hover{background:#f7f7f7}
.pman-chip .dot{width:7px;height:7px;border-radius:50%;}
.pman-chip .dot.blue{background:#2271b1}
.pman-chip .dot.green{background:#46b450}
.pman-chip.is-disabled{opacity:.45;cursor:default}				

/* Kōrero row tint */
tr.is-korero{ background: #fffdf5; } /* subtle warm tint */

/* Drawer */
.pman-drawer-overlay{position:absolute;inset:0;background:rgba(0,0,0,.1);display:none;z-index:14}
.pman-drawer{position:absolute;top:0;right:0;height:100%;width:min(520px,80%);max-width:520px;background:#fff;border-left:1px solid #e2e4e7;box-shadow:-8px 0 24px rgba(0,0,0,.06);transform:translateX(100%);transition:transform .18s ease;z-index:15;display:flex;flex-direction:column}
.pman-drawer.open{transform:translateX(0)}
.pman-drawer-header{display:flex;align-items:center;justify-content:space-between;padding:10px 14px;border-bottom:1px solid #ececec}
.pman-drawer-title{font-weight:600;margin:0;font-size:14px}
.pman-drawer-close{appearance:none;border:none;background:transparent;cursor:pointer;font-size:20px;line-height:1;padding:2px 6px}
.pman-drawer-body{overflow:auto;padding:10px 14px}
.pman-mini-list{margin:0;padding:0;list-style:none}
.pman-mini-list li{padding:8px 0;border-bottom:1px solid #efefef;display:flex;align-items:center;gap:8px}
.pman-mini-thumb{width:36px;height:36px;background:#f2f2f2;border:1px solid #e6e6e6;border-radius:4px;flex:0 0 36px;overflow:hidden}
.pman-mini-meta{display:flex;flex-direction:column;gap:2px;min-width:0}
.pman-mini-title{font-weight:600;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.pman-mini-sub{font-size:12px;color:#646970}				

