:root {
  --bg:#f7f8fb;
  --ink:#1c2451;
  --muted:#6c78a0;
  --card:#fff;
  --radius:14px;
  --tile: 180px;
  --gap: 14px;
}


* { box-sizing:border-box; }
body {
  margin:0;
  font-family:system-ui,-apple-system, Segoe UI, Roboto, Arial, sans-serif;
  color:var(--ink);
  background:var(--bg);
}

h1 {
  margin:0 0 12px;
  font-weight:800;
  font-size:28px;
}

/* Search bar */
.searchbox {
  display:flex;
  gap:8px;
  align-items:center;
  background:var(--card);
  border:1px solid #888888;
  border-radius:var(--radius);
  padding:10px 12px;
  /*margin-bottom:12px;*/
  max-width: 800px;    /* pick a size: 560–840px works well */
  width: 100%;
  margin: 0 auto; /* centers it; keeps your bottom margin */
}

.searchbox input[type="search"] {
  border:0;
  outline:0;
  width:100%;
  font-size:24px;      /* larger input text */
  background:transparent;
  color:var(--ink);
  flex: 1 1 auto;
  min-width: 0;        /* prevents overflow on narrow screens */
}

/* Placeholder color */
.searchbox input[type="search"]::placeholder {
  color: lightgray;   /* pick your color */
  opacity: 1;       /* Safari lowers opacity by default */
}

/* Optional legacy prefixes */
.searchbox input[type="search"]::-webkit-input-placeholder { color: lightgray; opacity: 1; }
.searchbox input[type="search"]::-moz-placeholder { color: lightgray; opacity: 1; }
.searchbox input[type="search"]:-ms-input-placeholder { color: lightgray; }
.searchbox input[type="search"]::-ms-input-placeholder { color: lightgray; }

.searchbox button {
  border:0;
  background:#1f4fff;
  color:#fff;
  border-radius:10px;
  padding:8px 12px;
  font-weight:500;
  font-size:24px;      /* larger button text */
  cursor:pointer;
}

.searchbox .icon {
  font-size:22px;
  line-height:1;
}

#searchForm {
  width: 100%;
  max-width: 800px;   /* tweak to taste */
  margin: 0 auto 12px;
}

/* Meta line (messages like “No results…”) */
.meta {
  font-size:24px;
  color:var(--muted);
  margin-bottom:12px;
}

/* allow up to 6 across, rows centered */
#grid {
  display: grid;
  gap: var(--gap);
  grid-template-columns: repeat(auto-fill, var(--tile)); /* fixed tile width */
  justify-content: center;                               /* center leftover space */
  margin-inline: auto;                                   /* center the grid block */
  margin-bottom: 60px;
  max-width: calc(6 * var(--tile) + 5 * var(--gap));     /* cap at 6 columns */
}

/* Results grid */
.grid {
  display:grid;
  gap:14px;
  grid-template-columns:repeat(auto-fill, minmax(180px, 1fr));
}

/* Cards */
.card {
  position:relative;
  background:var(--card);
  border:1px solid #e3e7f2;
  border-radius:calc(var(--radius) + 2px);
  overflow:hidden;
  text-decoration:none;
  color:inherit;
  transition:transform .06s ease, box-shadow .06s ease;

  /* center fixed-size thumbnail */
  display:flex;
  flex-direction:column;
  align-items:center;
}

.card:hover {
  transform:translateY(-1px);
  box-shadow:0 6px 18px rgba(16,19,31,.06);
}

/* 180x180 thumbnails (no stretch) */
.thumb {
  width:180px;
  height:180px;
  object-fit:cover;      /* use 'contain' if you prefer no crop */
  background:#eef2ff;
  border-radius:8px;     /* optional rounded thumbs */
  display:block;
  margin-top:10px;       /* small spacing from card edge */
}

/* Title */
.title {
  padding:10px 12px 12px;
  font-size:15px;
  font-weight:700;
  line-height:1.2;
  min-height:44px;
  text-align:center;     /* center under the centered image */
}

/* Premium lock badge */
.lock {
  position:absolute;
  top:8px;
  right:8px;
  background:rgba(16,19,31,.72);
  color:#fff;
  font-size:12px;
  padding:4px 8px;
  border-radius:999px;
}

/* Assist links (refine suggestions) */
.assist {
  display:flex;
  flex-wrap:wrap;
  gap:8px;
  margin:8px 0 0px;
}
.assist a {
  font-size:12px;
  color:#1f4fff;
  text-decoration:none;
  border:1px solid #cfe0ff;
  border-radius:999px;
  padding:4px 8px;
  background:#f8fbff;
}

/* Visually hidden (for a11y) */
.sr-only {
  position:absolute !important;
  clip:rect(1px, 1px, 1px, 1px);
  padding:0 !important;
  border:0 !important;
  height:1px !important;
  width:1px !important;
  overflow:hidden;
  white-space:nowrap;
}

/* Match the search bar width */
#tips {
  width: 100%;
  max-width: 800px;         /* keep in sync with #searchForm */
  margin: 0px auto 20px;    /* centered block, left-aligned text */
}

/* Left-aligned callout, no icon */
.tips {
  background: #f8fbff;
  border: 1px solid #cfe0ff;
  border-radius: var(--radius);
  padding: 12px 14px;
  text-align: left;
}

.tips-title {
  margin: 0 0 6px;
  font-size: 20px;
  font-weight: 800;
  color: var(--ink);
}

.tips-list {
  margin: 0;
  padding-left: 18px;
  font-size: 18px;
  color: var(--muted);
}

.tips-list li { margin: 4px 0; }



@media (min-width: 1024px) {
  .searchbox { max-width: 800px; }
}
