/* Base */
:root {
  --bg: #ffffff;
  --fg: #0f172a;
  --muted: #475569;
  --primary: #0ea5e9;
  --primary-ink: #0b4a6f;
  --surface: #f1f5f9;
  --border: #e2e8f0;
}

* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  color: var(--fg);
  background: var(--bg);
  line-height: 1.6;
}

.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 16px;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(255,255,255,0.9);
  backdrop-filter: saturate(180%) blur(8px);
  border-bottom: 1px solid var(--border);
}
.site-header .container { max-width: 90%; padding-left: 24px; padding-right: 24px; }
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 90px;
  flex-wrap: nowrap;
}
.brand {
  font-weight: 700;
  text-decoration: none;
  color: var(--fg);
  letter-spacing: 0.4px;
}
.brand-logo {
  height: 40px;
  width: auto;
  display: block;
}
/* Nav layout groups */
.nav {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: nowrap;
}
.nav .menu-left { gap: 32px; }
.nav .menu-right { gap: 18px; align-items: center; }
.nav ul {
  display: flex;
  gap: 16px;
  list-style: none;
  margin: 0;
  padding: 0;
  flex-wrap: nowrap;
}
.nav a { color: #666666; text-decoration: none; text-transform: uppercase; letter-spacing: 0.4px; font-weight: 600; font-size: 13px; white-space: nowrap; }
.nav a:hover { color: var(--primary); }

.nav .divider {
  width: 1px;
  height: 24px;
  background: #0f172a33;
  margin: 0 8px;
}

/* Subtle highlight band behind right-side items to mimic screenshot */
.site-header::after {
  content: "";
  position: absolute;
  right: 0; top: 0; bottom: 0;
  width: 22vw;
  background: linear-gradient(90deg, rgba(8,59,84,0.06), rgba(8,59,84,0.12) 60%, rgba(8,59,84,0.08));
  pointer-events: none;
}
.caret { font-size: 12px; margin-left: 6px; opacity: 0.6; }

/* Hero */
.hero {
  background: linear-gradient(180deg, var(--surface), transparent 60%);
  padding: 64px 0 24px;
}
.hero-copy h1 { margin: 0 0 12px; line-height: 1.25; }
.hero-copy p { color: var(--muted); margin: 0 0 20px; }
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.btn {
  display: inline-block;
  padding: 10px 16px;
  border: 1px solid var(--border);
  border-radius: 8px;
  text-decoration: none;
  color: var(--fg);
}
.btn.primary { background: #f97316; color: #fff; border-color: #f97316; }
.btn.primary:hover { background: #ea580c; }
.btn.blue { background: #3b82f6; color: #fff; border-color: #3b82f6; }
.btn.blue:hover { background: #2563eb; }

/* Features */
.features { padding: 32px 0; }
.features-header { display: flex; align-items: end; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.filters input {
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 8px;
  width: 260px;
  max-width: 100%;
}
.grid {
  list-style: none;
  padding: 0;
  margin: 20px 0 0;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
@media (max-width: 1000px) { .grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .grid { grid-template-columns: 1fr; } }

.card {
  border: 1px solid var(--border);
  border-radius: 12px;
  background: #fff;
  transition: transform 120ms ease, box-shadow 120ms ease;
}
.card:hover { transform: translateY(-2px); box-shadow: 0 6px 18px rgba(0,0,0,0.06); }
.card-link {
  display: block;
  padding: 18px;
  color: inherit;
  text-decoration: none;
}
.card-icon { font-size: 28px; }
.card h3 { margin: 10px 0 8px; }
.card p { margin: 0; color: var(--muted); }

/* Map */
.map-section { padding: 32px 0; background: var(--surface); border-top: 1px solid var(--border); }
.map-view {
  width: 100%;
  height: 520px;
  background: repeating-linear-gradient(45deg, #e2e8f0, #e2e8f0 10px, #f8fafc 10px, #f8fafc 20px);
  border: 1px solid var(--border);
  border-radius: 12px;
}

/* Sections & Footer */
.section { padding: 32px 0; }
.site-footer { border-top: 1px solid var(--border); padding: 24px 0; }
.footer-inner { display: flex; align-items: center; justify-content: space-between; gap: 12px; }

/* Welcome bar */
.welcome-bar {
  background: #f8fafc;
  border-bottom: 1px solid var(--border);
  color: var(--muted);
}
.welcome-bar p { margin: 10px 0; }

/* New footer matching provided layout */
.footer-topbar {
  background: #083b54;
  color: #e2f3fb;
  padding: 12px 0;
}
.footer-topbar a { color: #b8ecff; }

.footer-main { background: #ffffff; padding: 28px 0; }
.footer-main-inner { display: flex; align-items: center; gap: 20px; justify-content: center; text-align: center; flex-wrap: wrap; }
.footer-logo { height: 60px; width: auto; }
.footer-copy h3 { margin: 8px 0; font-size: 18px; }
.footer-copy p { margin: 6px 0; color: var(--muted); }

.footer-bottombar {
  background: #083b54;
  color: #e2f3fb;
  padding: 12px 0;
}

/* A11y */
.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 1px, 1px);
  border: 0;
}

/* Upload button styling */
label[for="rag-pdf"]:hover {
    background: #f1f5f9 !important;
    border-color: #cbd5e1 !important;
    transform: translateY(-1px);
}

label[for="rag-pdf"]:active {
    transform: translateY(0);
}

