:root {
  color-scheme: light;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: #17211d;
  background: #eef2ee;
  --green-dark: #12372a;
  --green: #087f5b;
  --muted: #52615a;
}

* { box-sizing: border-box; }
html, body { min-height: 100%; margin: 0; }
body { background: #eef2ee; }

.search-shell { min-height: 100vh; min-height: 100dvh; }
.search-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 76px;
  padding: calc(0.75rem + env(safe-area-inset-top)) calc(clamp(1rem, 3vw, 2rem) + env(safe-area-inset-right)) 0.75rem calc(clamp(1rem, 3vw, 2rem) + env(safe-area-inset-left));
  color: #f7fbf8;
  background: var(--green-dark);
  box-shadow: 0 2px 14px rgba(0, 0, 0, 0.2);
}

h1, p { margin-top: 0; }
h1 { margin-bottom: 0; font-size: clamp(1.35rem, 3vw, 2rem); line-height: 1.05; }
.eyebrow { margin-bottom: 0.2rem; font-size: 0.72rem; font-weight: 750; letter-spacing: 0.12em; text-transform: uppercase; opacity: 0.76; }
.map-link {
  min-height: 42px;
  padding: 0.58rem 0.9rem;
  border: 1px solid rgba(255,255,255,0.3);
  border-radius: 999px;
  color: inherit;
  background: rgba(255,255,255,0.1);
  font-weight: 650;
  text-decoration: none;
}
.map-link:hover, .map-link:focus-visible { background: rgba(255,255,255,0.2); outline: 2px solid #ffe066; outline-offset: 2px; }

.search-content {
  width: min(52rem, 100%);
  margin: 0 auto;
  padding: 1.25rem calc(1rem + env(safe-area-inset-right)) calc(2rem + env(safe-area-inset-bottom)) calc(1rem + env(safe-area-inset-left));
}
.search-label { display: block; margin-bottom: 0.45rem; font-size: 0.86rem; font-weight: 750; }
.search-input {
  width: 100%;
  min-height: 52px;
  padding: 0.72rem 0.9rem;
  border: 2px solid #82988d;
  border-radius: 0.72rem;
  color: #17211d;
  background: white;
  font: inherit;
  font-size: 1rem;
  box-shadow: 0 3px 14px rgba(10,35,25,0.08);
}
.search-input:focus { border-color: var(--green); outline: 3px solid rgba(8,127,91,0.2); }
.search-status { min-height: 1.4rem; margin: 0.7rem 0; color: var(--muted); font-size: 0.82rem; }
.search-status.error { color: #8b2c2c; }
.search-results { display: grid; gap: 0.5rem; margin: 0; padding: 0; list-style: none; }
.search-result {
  display: grid;
  min-height: 54px;
  align-content: center;
  gap: 0.16rem;
  padding: 0.66rem 0.8rem;
  border: 1px solid #d2ddd7;
  border-radius: 0.68rem;
  color: #17392c;
  background: white;
  box-shadow: 0 2px 9px rgba(10,35,25,0.05);
  text-decoration: none;
}
.search-result:hover, .search-result:focus-visible { border-color: var(--green); background: #f2fbf7; outline: 2px solid #ffe066; outline-offset: 1px; }
.search-result-name { font-size: 0.92rem; font-weight: 730; line-height: 1.25; }
.search-result-references { color: #087f5b; font-size: 0.72rem; font-weight: 750; }

@media (max-width: 640px) {
  .search-header {
    min-height: 60px;
    padding: calc(0.48rem + env(safe-area-inset-top)) calc(0.7rem + env(safe-area-inset-right)) 0.48rem calc(0.7rem + env(safe-area-inset-left));
  }
  .search-header .eyebrow { margin-bottom: 0.08rem; font-size: 0.58rem; }
  h1 { font-size: 1.18rem; }
  .map-link { display: grid; min-height: 44px; padding: 0.42rem 0.75rem; place-items: center; }
  .search-content { padding-top: 0.9rem; }
  .search-input { min-height: 50px; font-size: 16px; }
}
