/* Site search results. Loaded only by graph/search.html, after calendar.css.
 *
 * The vocabulary is the one already shipped: the panel, tinted head and count
 * of a /places/ section (places.css), the compact row and note of a calendar
 * row (calendar.css), and the stacked date block and front doors of the home
 * page (home.css). The doors are restated here rather than imported because
 * home.css is loaded by today.html alone; the custom properties they use are
 * global in site.css and desk-theme.css. Nothing here decides what a result may
 * say -- the view and graph/search.py already did that. */

.search-bar{margin-bottom:18px}

.result-group{margin:0 0 22px;border:1px solid var(--panel-line);border-radius:var(--panel-radius);overflow:hidden;background:var(--surface)}
.result-group-head{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:16px 21px;background:var(--tint);border-top:4px solid var(--accent);border-bottom:1px solid var(--panel-line)}
.result-group-head h2{font:600 28px/1.08 var(--display);color:var(--tone-ink);margin:0}
.result-group-head p{margin:5px 0 0;font-size:14px;line-height:1.45;color:var(--tone-ink);opacity:.85;max-width:70ch}
.result-group-count{font:600 30px/1 var(--display);color:var(--accent);opacity:.55}
.result-rows{padding:4px 21px 8px}
.result-more{margin:0;padding:12px 21px 16px;border-top:1px solid var(--line);font-size:14px;color:var(--ink2)}

/* A row: the date it was ordered by, the title, one line of context, the source. */
.result-row{display:grid;grid-template-columns:52px minmax(0,1fr) 40px;align-items:start;gap:4px 14px;padding:14px 0;border-bottom:1px solid var(--line)}
.result-rows>.result-row:last-child{border-bottom:0}
.result-date{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:1px;padding:5px 0;background:var(--tint);border-radius:7px;color:var(--tone-ink);font:11px var(--mono);letter-spacing:.06em;text-transform:uppercase}
.result-date b{font:700 24px/1 var(--display)}
.result-date small{font:9px var(--mono);letter-spacing:.05em}
.result-mark{width:52px;height:46px;border-radius:7px;background:#fff;border:1px solid var(--panel-line);display:grid;place-items:center;overflow:hidden;font:600 14px var(--display);color:var(--tone-ink)}
.result-mark img{max-width:100%;max-height:100%;object-fit:contain;padding:4px}
.result-copy{min-width:0}
.result-copy h3{margin:0;font:600 19px/1.25 var(--display)}
.result-meta{display:flex;flex-wrap:wrap;align-items:baseline;gap:4px 10px;margin:5px 0 0;font:12px var(--mono);letter-spacing:.03em;text-transform:uppercase;color:var(--ink2)}
.result-meta .cal-cat{color:var(--tone-ink)}
.result-copy .cal-note{margin:6px 0 0}
.result-copy>.source{margin-top:8px}
.result-row>.save{grid-column:3;grid-row:1}

/* The pre-query page: three doors into what search covers. */
.search-doors{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin:4px 0 10px}
.search-doors .front-door{display:flex;flex-direction:column;gap:5px;min-height:96px;padding:15px 16px;border-radius:12px;color:#f7f4ec;background:#123c56;position:relative;transition:transform .12s}
.search-doors .front-door strong{font:700 21px/1.05 var(--display);letter-spacing:.015em}
.search-doors .front-door small{font-size:12px;line-height:1.35;color:#e6edf1}
.search-doors .front-door>span{position:absolute;right:14px;bottom:12px;font-size:17px;line-height:1}
.search-doors .front-door:hover,.search-doors .front-door:focus-visible{color:var(--amber);transform:translateY(-2px)}
.search-doors .front-door:focus-visible{outline:3px solid var(--navy);outline-offset:3px}
.search-doors .door-red{background:#b31f2b}
.search-doors .door-green{background:#2f6b4f}

@media(max-width:650px){
.result-group-head{padding:14px 16px}
.result-group-head h2{font-size:24px}
.result-group-head p{font-size:13px}
.result-rows{padding:2px 16px 6px}
.result-more{padding:11px 16px 14px}
.result-row{grid-template-columns:46px minmax(0,1fr) 44px;gap:4px 11px}
.result-date{font-size:10px}
.result-date b{font-size:21px}
.result-mark{width:46px;height:42px}
.result-copy h3{font-size:17px}
.result-row>.save{width:44px;min-width:44px;height:44px;margin:-8px -11px 0 0}
.search-doors{grid-template-columns:1fr;gap:9px}
.search-doors .front-door{min-height:74px;padding:13px}
.search-doors .front-door strong{font-size:19px}
}
@media(prefers-reduced-motion:reduce){.search-doors .front-door{transition:none}}
@media print{.search-bar,.search-doors,.result-row>.save,.result-more a{display:none}
.result-group{break-inside:auto;border-radius:0}.result-row{break-inside:avoid}}
