:root {
  --bg: #eef6ff;
  --card: #ffffff;
  --line: #cfe5fb;
  --text: #0f2340;
  --muted: #5f7792;
  --blue: #1184de;
  --blue-2: #33a6ff;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: Manrope, sans-serif;
  color: var(--text);
  background: linear-gradient(150deg, #ffffff 0%, #edf6ff 50%, #e4f1ff 100%);
}

.bg-mark {
  position: fixed;
  right: -120px;
  top: -120px;
  width: 380px;
  height: 380px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(17, 132, 222, 0.26) 0%, rgba(17, 132, 222, 0) 70%);
  pointer-events: none;
}

.page {
  width: min(1120px, calc(100% - 24px));
  margin: 28px auto 40px;
  display: grid;
  gap: 18px;
}

.hero,
.record,
.empty {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 20px;
  box-shadow: 0 14px 28px rgba(17, 132, 222, 0.1);
}

.hero {
  padding: 24px;
}

.hero-badge {
  display: inline-block;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: #fff;
  background: linear-gradient(120deg, #1ca2ff, #0d78cc);
  border-radius: 999px;
  padding: 7px 12px;
  margin-bottom: 10px;
}

h1 {
  margin: 0;
  font-size: clamp(30px, 4.2vw, 46px);
  line-height: 1.05;
}

.hero p {
  margin: 10px 0 20px;
  color: var(--muted);
}

.search-form {
  display: grid;
  gap: 8px;
}

.search-form label {
  font-weight: 700;
}

.search-row {
  display: grid;
  grid-template-columns: 1fr 140px;
  gap: 10px;
}

.search-row input {
  width: 100%;
  border: 1px solid #bcdfff;
  border-radius: 12px;
  padding: 13px 15px;
  font: inherit;
  background: #fafdff;
  color: var(--text);
}

.search-row button {
  border: 0;
  border-radius: 12px;
  font: inherit;
  font-weight: 800;
  color: #fff;
  background: linear-gradient(120deg, var(--blue-2), var(--blue));
  cursor: pointer;
}

.error {
  margin: 10px 0 0;
  color: #d13c48;
  font-weight: 700;
}

.results h2 {
  margin: 0 0 10px;
  font-size: 24px;
}

.results h2 span {
  color: var(--blue);
}

.record {
  padding: 16px;
  margin-bottom: 12px;
}

.meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  margin-bottom: 12px;
  color: var(--muted);
}

.tag {
  background: #e5f3ff;
  color: #0d78cc;
  font-weight: 800;
  border-radius: 999px;
  padding: 3px 10px;
}

.info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 10px;
}

.info-grid small {
  color: var(--muted);
  font-weight: 700;
}

.info-grid p {
  margin: 4px 0 0;
  font-weight: 700;
}

.evidence-links {
  margin-top: 12px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.evidence-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 9px 13px;
  border-radius: 10px;
  border: 1px solid #a9d6fb;
  background: #f2f9ff;
  color: #0d78cc;
  text-decoration: none;
  font-weight: 700;
}

.evidence-link:hover {
  background: #e5f3ff;
}

.empty {
  padding: 20px;
  font-weight: 700;
  color: var(--muted);
}

.loader-modal {
  position: fixed;
  inset: 0;
  display: none;
  place-items: center;
  background: rgba(6, 22, 39, 0.34);
  z-index: 999;
}

.loader-modal.show {
  display: grid;
}

.loader-box {
  width: min(320px, 92vw);
  border-radius: 16px;
  border: 1px solid var(--line);
  background: #fff;
  padding: 16px;
  text-align: center;
}

.loader-box img {
  width: 120px;
  height: 120px;
  object-fit: contain;
}

.loader-box p {
  margin: 8px 0 0;
  color: #1b83cf;
  font-weight: 700;
}

@media (max-width: 720px) {
  .page {
    width: calc(100% - 14px);
    margin-top: 12px;
  }

  .hero {
    padding: 16px;
  }

  .search-row {
    grid-template-columns: 1fr;
  }
}
