:root {
  --bg-page: #f3f4f6;
  --bg-card: #ffffff;
  --border: #e5e7eb;
  --border-hero: #111827;
  --text: #0f172a;
  --muted: #6b7280;
  --accent: #2563eb;
  --accent-dark: #1d4ed8;
  --button-bg: #1e3a8a;
  --button-bg-hover: #1d3a7a;
  --radius-lg: 18px;
  --shadow-soft: 0 18px 40px rgba(15,23,42,0.08);
  --max-width: 1180px;
}

*, *::before, *::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--bg-page);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  color: var(--accent-dark);
}

.page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* GENERIC INNER WRAPPER FOR MAIN CONTENT */
.inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 16px 40px;
}

/* FULL-WIDTH HEADER */

header {
  background: #ffffff;
  border-bottom: 1px solid var(--border);
}

.header-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 16px 16px;
  display: flex;
  align-items: center;
}

/* LOGO */

.brand {
  display: flex;
  align-items: center;
}

.brand-link {
  display: inline-flex;
  align-items: center;
}

.brand-logo {
  display: block;
  max-width: 100%;
  height: auto;   /* use natural 160x53 ratio from HTML attributes */
}

/* NAV */

.nav-links {
  display: flex;
  gap: 24px;
  font-size: 0.9rem;
  margin-left: auto;
}

.nav-links a {
  color: #111827;
  font-weight: 600;
}

.nav-links a:hover {
  color: var(--accent-dark);
}

/* HERO */

.hero-wrap {
  margin-top: 32px;
  margin-bottom: 26px;
}

.hero-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-hero);
  box-shadow: 0 26px 60px rgba(15, 23, 42, 0.18);
  padding: 32px 24px 26px;
  text-align: center;
}

h1 {
  font-size: 2rem;
  line-height: 1.2;
  margin-bottom: 12px;
}

.hero-subtitle {
  max-width: 720px;
  margin: 0 auto 24px;
  color: #374151;
  line-height: 1.6;
  font-weight: 500;
}

.hero-subtitle strong {
  color: var(--text);
  font-weight: 600;
}

/* SEARCH */

.search-form {
  display: flex;
  flex-direction: column;
  gap: 10px;
  align-items: stretch;
}

.search-input-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid #cbd5e1;
  background: #ffffff;
}

.search-input-wrap svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.search-input {
  border: none;
  flex: 1;
  font-size: 0.98rem;
  outline: none;
  color: var(--text);
}

.search-input::placeholder {
  color: #9ca3af;
}

.search-button {
  border-radius: 12px;
  border: 1px solid #1e3a8a;
  background: var(--button-bg);
  color: #ffffff;
  font-weight: 700;
  padding: 12px 24px;
  cursor: pointer;
  font-size: 0.98rem;
  box-shadow: 0 18px 40px rgba(15,23,42,0.55);
  transition: transform 0.15s ease;
}

.search-button:hover {
  background: var(--button-bg-hover);
  transform: translateY(-1px);
}

/* PROGRESS BAR */

.search-progress {
  margin-top: 10px;
  width: 100%;
  height: 6px;
  border-radius: 999px;
  background: #e5e7eb;
  overflow: hidden;
  position: relative;
  display: none; /* shown only while searching */
}

.search-progress-bar {
  position: absolute;
  inset: 0;
  width: 40%;
  background: linear-gradient(90deg, #1e3a8a, #2563eb);
  border-radius: inherit;
  transform: translateX(-100%);
  animation: progressSweep 1.2s ease-in-out infinite;
}

.hero-card.searching .search-progress {
  display: block;
}

@keyframes progressSweep {
  0%   { transform: translateX(-100%); }
  50%  { transform: translateX(35%); }
  100% { transform: translateX(120%); }
}

/* MAIN SECTIONS */

main {
  max-width: var(--max-width);
  margin: 0 auto 40px;
  padding: 0 16px;
}

.section {
  background: #fff;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-soft);
  padding: 22px 18px;
  margin-bottom: 20px;
}

.section-inner {
  max-width: 820px;
  margin: 0 auto;
}

.section h2 {
  font-size: 1.4rem;
  margin-bottom: 12px;
}

.section p {
  font-size: 0.96rem;
  line-height: 1.7;
  margin-bottom: 10px;
}

/* RESULTS */

.results-section {
  margin-bottom: 24px;
}

.results-title {
  font-size: 1.4rem;
  margin-bottom: 8px;
}

.results-status {
  font-size: 0.96rem;
  color: var(--muted);
  margin: 0 0 14px;
}

/* Spinner on status when loading */
.results-section.is-loading .results-status::before {
  content: "";
  display: inline-block;
  width: 14px;
  height: 14px;
  margin-right: 8px;
  border-radius: 999px;
  border: 2px solid #e5e7eb;
  border-top-color: var(--accent);
  animation: spin 0.6s linear infinite;
  vertical-align: -2px;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.results-grid {
  display: grid;
  gap: 16px;
}

/* RESULT CARDS */

.result-card {
  background: #ffffff;
  border-radius: 14px;
  border: 1px solid var(--border);
  box-shadow: 0 10px 28px rgba(15,23,42,0.06);
  padding: 14px 14px 12px;
}

/* Background colors based on decision */
.result-found {
  background-color: #E9FDF3;
}

.result-not_found {
  background-color: #FFF5F5;
}

.result-unknown {
  background-color: #FFFBEA;
}

.result-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
}

.result-platform {
  font-weight: 600;
  font-size: 0.98rem;
  color: #111827;
}

.result-decision {
  font-size: 0.78rem;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 999px;
  border: 1px solid transparent;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.decision-found {
  background: #ecfdf3;
  color: #166534;
  border-color: #bbf7d0;
}

.decision-not_found {
  background: #fef2f2;
  color: #b91c1c;
  border-color: #fecaca;
}

.decision-unknown {
  background: #fefce8;
  color: #92400e;
  border-color: #fef3c7;
}

/* URL line */

.result-url {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  margin: 0;
}

.result-url-label {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #9ca3af;
}

.result-url-code {
  width: 100%;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  font-size: 0.82rem;
  background: #f9fafb;
  border-radius: 10px;
  padding: 6px 8px;
  border: 1px dashed #e5e7eb;
  color: #111827;
  word-break: break-all;
}

/* CTA */

.results-cta {
  margin-top: 16px;
  text-align: center;
}

.cta-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 11px 22px;
  border-radius: 999px;
  border: none;
  background: linear-gradient(135deg, #1e3a8a, #2563eb);
  color: #ffffff;
  font-size: 0.95rem;
  font-weight: 700;
  box-shadow: 0 18px 40px rgba(37,99,235,0.35);
  cursor: pointer;
  transition: transform 0.15s ease;
}

.cta-button:hover,
.cta-button:focus-visible {
  transform: translateY(-1px);
}

/* Responsive grid */

@media (min-width: 640px) {
  h1 {
    font-size: 2.3rem;
  }

  .search-form {
    flex-direction: row;
    gap: 12px;
  }

  .search-input-wrap {
    flex: 3 1 0;
  }

  .search-button {
    flex: 1 1 0;
    width: auto;
  }

  .results-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 900px) {
  h1 {
    font-size: 2.6rem;
  }

  .hero-card {
    padding: 36px 40px 30px;
  }
}

/* FOOTER */

footer {
  border-top: 1px solid var(--border);
  background: #ffffff;
  margin-top: 40px;
}

.footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 28px 16px 32px;
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 22px;
  font-size: 0.95rem;
}

.footer-nav a {
  color: #1f2937;
  font-weight: 600;
}

.footer-nav a:hover,
.footer-nav a:focus-visible {
  color: #000;
  text-decoration: underline;
}

.footer-mission {
  max-width: 780px;
  margin: 0 auto;
  font-size: 0.95rem;
  line-height: 1.55;
  color: #1f2937;
}

.footer-copy {
  margin: 6px 0 0;
  font-size: 0.93rem;
  color: #1f2937;
}

/* GUIDE IMAGES (if any inner guides reuse this CSS) */

.section article figure {
  margin: 1.5rem 0;
}

.section article img,
.section article figure img {
  display: block;
  width: 100% !important;
  max-width: 100% !important;
  height: auto !important;
  margin: 1rem auto;
}
