/**
 * Shared SMGIS site chrome — navbar, hero banner, footer.
 * Used by the tools landing page and every individual tool page so the
 * Tools section reads as part of smgis.in rather than a separate app.
 *
 * Palette approximates the live smgis.in brand (navy/teal gradient hero,
 * amber-orange CTA accent). If the exact brand hex values are provided,
 * only the variables below need updating — every page inherits them.
 */

:root {
  --site-navy-deep: #0B2436;
  --site-navy: #123B3A;
  --site-teal: #0F6E5D;
  --site-orange: #EF9D3B;
  --site-orange-dark: #D9822A;
  --site-orange-soft: #FDEEDA;
  --site-white: #FFFFFF;
  --site-muted-on-dark: #B9C6CC;
}

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

/* ---------- Page shell — self-contained centering, independent of Bootstrap ----------
   Every page uses this instead of Bootstrap's .container for its outer structure,
   so centering and max-width never depend on whether Bootstrap's CSS loaded. */

.page-shell {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  width: 100%;
}

.page-shell--narrow {
  max-width: 920px;
}

@media (max-width: 576px) {
  .page-shell { padding: 0 16px; }
}

/* ---------- Top navigation bar (every page) — same structure as the homepage ---------- */

.site-navbar {
  background: linear-gradient(135deg, var(--site-navy-deep), var(--site-teal));
}

.site-navbar-inner {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 36px;
  padding: 14px 0;
}

.site-logo {
  display: flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
  color: var(--site-white);
}

.site-logo-mark {
  width: 54px;
  height: 54px;
  border-radius: 12px;
  background: var(--site-teal);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.site-logo-wordmark {
  font-family: 'Inter', system-ui, sans-serif;
  font-weight: 700;
  font-size: 22px;
  letter-spacing: 0.01em;
  line-height: 1.2;
}

.site-logo-tagline {
  font-size: 11.5px;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--site-muted-on-dark);
  font-weight: 500;
}

.site-nav-center {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.site-nav-links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 30px;
  list-style: none;
  margin: 0;
  padding: 0;
  flex-wrap: wrap;
}

.site-nav-links a {
  color: var(--site-white);
  text-decoration: none;
  font-size: 13.5px;
  font-weight: 500;
  opacity: 0.85;
}

.site-nav-links a:hover {
  opacity: 1;
}

.site-nav-links a.active {
  opacity: 1;
  color: var(--site-orange);
  font-weight: 600;
}

.site-header-stats {
  display: flex;
  justify-content: center;
  gap: 48px;
  padding-top: 10px;
  border-top: 1px solid rgba(255,255,255,0.08);
}

.site-hstat { text-align: center; }
.site-hstat strong {
  display: block;
  font-family: 'IBM Plex Mono', 'Courier New', monospace;
  font-size: 17px;
  font-weight: 700;
  color: var(--site-orange);
}
.site-hstat span {
  font-size: 9.5px;
  color: var(--site-muted-on-dark);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.site-nav-cta-col {
  display: flex;
  align-items: center;
}

.site-nav-cta {
  border: 1px solid rgba(255,255,255,0.3);
  background: transparent;
  color: var(--site-white);
  font-weight: 600;
  font-size: 13px;
  padding: 8px 16px;
  border-radius: 5px;
  text-decoration: none;
  white-space: nowrap;
}

.site-nav-cta:hover {
  border-color: var(--site-orange);
  color: var(--site-orange);
}

@media (max-width: 900px) {
  .site-navbar-inner { grid-template-columns: auto auto; gap: 14px; justify-content: space-between; }
  .site-nav-center { display: none; }
  .site-nav-cta-col { display: none; }
  .site-nav-burger { display: flex; }
}
@media (min-width: 901px) {
  .site-nav-burger { display: none; }
  .site-nav-mobile-panel { display: none; }
}

.site-nav-burger {
  flex-direction: column; justify-content: center; align-items: center; gap: 5px;
  width: 40px; height: 40px; border: none; background: none; cursor: pointer; padding: 0;
}
.site-nav-burger span {
  display: block; width: 22px; height: 2px; background: #fff;
  transition: transform 0.2s ease, opacity 0.2s ease;
}
.site-nav-burger.is-open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.site-nav-burger.is-open span:nth-child(2) { opacity: 0; }
.site-nav-burger.is-open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.site-nav-mobile-panel {
  max-height: 0; overflow: hidden; background: var(--site-navy-deep, #0B2530);
  transition: max-height 0.25s ease;
}
.site-nav-mobile-panel.is-open { max-height: 480px; }
.site-nav-mobile-links { list-style: none; margin: 0; padding: 8px 20px 16px; display: flex; flex-direction: column; }
.site-nav-mobile-links li { border-bottom: 1px solid rgba(255,255,255,0.1); }
.site-nav-mobile-links li:last-child { border-bottom: none; }
.site-nav-mobile-links a {
  display: block; padding: 12px 4px; font-size: 15px; color: #fff; text-decoration: none;
}
.site-nav-mobile-cta {
  margin-top: 10px; text-align: center; background: var(--site-orange, #EF9D3B); color: #fff !important;
  border-radius: 6px; font-weight: 700;
}
@media (max-width: 480px) {
  .site-logo-mark { width: 40px; height: 40px; border-radius: 9px; }
  .site-logo-wordmark { font-size: 17px; }
  .site-logo-tagline { font-size: 9.5px; }
  .site-nav-cta { font-size: 11.5px; padding: 7px 11px; }
}

/* ---------- Hero banner (landing/tools directory page only) ---------- */

/* ---------- Hero banner (landing/tools directory page only) ---------- */

.site-hero {
  background: linear-gradient(135deg, var(--site-navy-deep), var(--site-teal));
  color: var(--site-white);
  padding: 56px 0 64px;
  position: relative;
  overflow: hidden;
}

.site-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0.15;
  background-image:
    repeating-linear-gradient(0deg, rgba(255,255,255,0.4) 0, rgba(255,255,255,0.4) 1px, transparent 1px, transparent 64px),
    repeating-linear-gradient(90deg, rgba(255,255,255,0.4) 0, rgba(255,255,255,0.4) 1px, transparent 1px, transparent 64px);
  pointer-events: none;
}

.site-hero-inner {
  position: relative;
  max-width: 62ch;
}

.site-hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--site-orange);
  color: var(--site-orange);
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 6px 14px;
  border-radius: 999px;
  margin-bottom: 20px;
}

.site-hero-badge .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--site-orange);
}

.site-hero h1 {
  font-size: 38px;
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 16px;
  letter-spacing: -0.01em;
}

.site-hero p.hero-subtext {
  font-size: 15.5px;
  color: var(--site-muted-on-dark);
  line-height: 1.65;
  margin-bottom: 0;
}

/* ---------- Slim sub-header (individual tool pages) ---------- */

.tool-subheader {
  background: var(--smgis-ink, #1E2A32);
  color: #fff;
  padding: 18px 0;
}

/* ---------- Footer (every page) ---------- */

.site-footer {
  background: var(--site-navy-deep);
  color: var(--site-muted-on-dark);
  padding: 22px 0;
  margin-top: auto;
}

.site-footer-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  text-align: center;
}

.site-footer-links {
  display: flex;
  gap: 18px;
  list-style: none;
  margin: 0 0 4px;
  padding: 0;
  flex-wrap: wrap;
  justify-content: center;
}

.site-footer-links a {
  color: var(--site-muted-on-dark);
  text-decoration: none;
  font-size: 12.5px;
}

.site-footer-links a:hover {
  color: var(--site-white);
}

.site-footer-copyright {
  font-size: 12px;
  color: var(--site-muted-on-dark);
  margin: 0;
}

/* ---------- Responsive ---------- */

@media (max-width: 767px) {
  .site-nav-links { display: none; }
  .site-hero h1 { font-size: 28px; }
  .site-hero { padding: 40px 0 48px; }
}

/* ---------- Consultation CTA button for LIGHT backgrounds (e.g. inside
   .seo-cta boxes) — a solid fill, unlike .site-nav-cta's transparent/
   white-text style which is only legible against the dark nav gradient.
   Fixes a real bug: .site-nav-cta's white text was invisible against
   .seo-cta's light background until hover changed its color. ---------- */
.seo-cta-btn {
  display: inline-block;
  background: var(--smgis-accent, #EF9D3B);
  color: #ffffff;
  font-weight: 700;
  font-size: 13px;
  padding: 9px 18px;
  border-radius: 5px;
  text-decoration: none;
  white-space: nowrap;
  border: none;
}
.seo-cta-btn:hover {
  background: var(--smgis-accent-dark, #D9822A);
  color: #ffffff;
}
