/* HavenGo core theme
   Copy to: /static/havengo/css/havengo-theme.css
*/
:root {
  --hg-navy: #0B1F3A;
  --hg-navy-2: #102B4A;
  --hg-green: #00B268;
  --hg-green-dark: #008F56;
  --hg-teal: #009D9A;
  --hg-blue: #4DA8FF;
  --hg-mint: #E6F6F1;
  --hg-bg: #F7FAFC;
  --hg-card: #FFFFFF;
  --hg-border: #DDE7EE;
  --hg-text: #102033;
  --hg-muted: #64748B;
  --hg-warning: #F59E0B;
  --hg-danger: #DC2626;
  --hg-success: #16A34A;

  --hg-radius-xs: 6px;
  --hg-radius-sm: 8px;
  --hg-radius-md: 12px;
  --hg-radius-lg: 16px;
  --hg-shadow-sm: 0 6px 18px rgba(11, 31, 58, 0.08);
  --hg-shadow-md: 0 16px 42px rgba(11, 31, 58, 0.12);
  --hg-shadow-soft: 0 22px 70px rgba(11, 31, 58, 0.14);
  --hg-focus: 0 0 0 3px rgba(0, 178, 104, 0.2);
  --hg-font: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

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

html {
  min-height: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100%;
  color: var(--hg-text);
  background: var(--hg-bg);
  font-family: var(--hg-font);
  font-size: 16px;
  line-height: 1.5;
}

body.hg-theme,
.hg-theme {
  color: var(--hg-text);
  background:
    linear-gradient(180deg, rgba(230, 246, 241, 0.58), rgba(247, 250, 252, 0.86) 340px),
    var(--hg-bg);
  font-family: var(--hg-font);
}

img,
svg {
  max-width: 100%;
  height: auto;
}

a {
  color: var(--hg-teal);
  font-weight: 700;
  text-decoration-thickness: 0.09em;
  text-underline-offset: 0.17em;
}

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

:focus-visible {
  outline: none;
  box-shadow: var(--hg-focus);
}

h1,
h2,
h3,
h4,
h5,
h6 {
  color: var(--hg-navy);
  font-weight: 800;
  letter-spacing: 0;
  line-height: 1.12;
  margin: 0 0 0.55em;
}

h1 {
  font-size: clamp(2.35rem, 6vw, 4.75rem);
}

h2 {
  font-size: clamp(1.9rem, 4vw, 3rem);
}

h3 {
  font-size: clamp(1.35rem, 2.6vw, 2rem);
}

p {
  margin: 0 0 1rem;
}

.hg-container {
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
}

.hg-container-sm {
  width: min(760px, calc(100% - 32px));
  margin: 0 auto;
}

.hg-app-shell {
  min-height: 100vh;
  color: var(--hg-text);
  background: var(--hg-bg);
}

.hg-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 255, 255, 0.94);
  border-bottom: 1px solid var(--hg-border);
  backdrop-filter: blur(16px);
}

.hg-header-inner {
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.hg-logo {
  display: block;
  width: auto;
  height: 44px;
}

.hg-nav {
  display: flex;
  align-items: center;
  gap: 6px;
}

.hg-nav a {
  display: inline-flex;
  min-height: 40px;
  align-items: center;
  justify-content: center;
  color: var(--hg-navy);
  text-decoration: none;
  border-radius: var(--hg-radius-sm);
  padding: 0 14px;
  font-size: 0.94rem;
  font-weight: 750;
}

.hg-nav a:hover,
.hg-nav a.is-active {
  color: var(--hg-green-dark);
  background: var(--hg-mint);
}

.hg-section {
  padding: 72px 0;
}

.hg-section-tight {
  padding: 44px 0;
}

.hg-section-title {
  max-width: 760px;
  color: var(--hg-navy);
  font-size: clamp(2rem, 4.6vw, 3.2rem);
}

.hg-section-copy {
  max-width: 700px;
  color: var(--hg-muted);
  font-size: 1.08rem;
}

.hg-eyebrow {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  color: var(--hg-green-dark);
  font-size: 0.78rem;
  font-weight: 850;
  letter-spacing: 0;
  text-transform: uppercase;
}

.hg-title {
  max-width: 780px;
  color: var(--hg-navy);
  font-size: clamp(2.5rem, 6vw, 4.9rem);
  line-height: 1.02;
}

.hg-subtitle {
  max-width: 720px;
  color: var(--hg-muted);
  font-size: clamp(1.08rem, 2vw, 1.35rem);
  line-height: 1.62;
}

.hg-muted {
  color: var(--hg-muted);
}

.hg-text-navy {
  color: var(--hg-navy);
}

.hg-text-green {
  color: var(--hg-green-dark);
}

.hg-bg-light {
  background: var(--hg-bg);
}

.hg-bg-mint {
  background: var(--hg-mint);
}

.hg-bg-navy {
  background: var(--hg-navy);
  color: rgba(255, 255, 255, 0.82);
}

.hg-hero {
  position: relative;
  overflow: hidden;
  padding: 82px 0 68px;
  color: var(--hg-text);
  background:
    radial-gradient(circle at 18% 18%, rgba(77, 168, 255, 0.16), transparent 28%),
    linear-gradient(135deg, #FFFFFF 0%, #F4FBF8 52%, #ECF8F8 100%);
}

.hg-hero::after {
  content: "";
  position: absolute;
  inset: auto -7% -80px -7%;
  height: 190px;
  pointer-events: none;
  background: url("/static/havengo/backgrounds/wave-pattern.svg") center / cover no-repeat;
  opacity: 0.44;
}

.hg-hero-light {
  color: var(--hg-text);
  background:
    url("/static/havengo/backgrounds/connection-pattern.svg") center / 560px auto repeat,
    linear-gradient(180deg, #FFFFFF 0%, #F1FBF7 100%);
}

.hg-hero-light .hg-subtitle {
  color: var(--hg-muted);
}

.hg-hero-dark {
  color: rgba(255, 255, 255, 0.86);
  background:
    url("/static/havengo/backgrounds/route-map-dark.svg") center / cover no-repeat,
    linear-gradient(135deg, var(--hg-navy) 0%, var(--hg-navy-2) 100%);
}

.hg-hero-dark h1,
.hg-hero-dark h2,
.hg-hero-dark h3,
.hg-hero-dark .hg-title,
.hg-hero-dark .hg-section-title {
  color: #FFFFFF;
}

.hg-hero-dark .hg-eyebrow {
  color: #9DF4C7;
}

.hg-hero-dark .hg-subtitle,
.hg-hero-dark .hg-section-copy {
  color: rgba(255, 255, 255, 0.78);
}

.hg-grid-2,
.hg-grid-3,
.hg-grid-4 {
  display: grid;
  gap: 18px;
}

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

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

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

.hg-card {
  background: var(--hg-card);
  border: 1px solid var(--hg-border);
  border-radius: var(--hg-radius-sm);
  box-shadow: var(--hg-shadow-sm);
  padding: 24px;
}

.hg-card-title {
  margin: 0 0 8px;
  color: var(--hg-navy);
  font-size: 1.15rem;
  font-weight: 850;
}

.hg-card-text {
  margin: 0;
  color: var(--hg-muted);
}

.hg-pill {
  display: inline-flex;
  min-height: 30px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 999px;
  padding: 0 12px;
  background: var(--hg-mint);
  color: var(--hg-green-dark);
  font-size: 0.78rem;
  font-weight: 850;
}

.hg-surface {
  background: var(--hg-card);
  border: 1px solid var(--hg-border);
  border-radius: var(--hg-radius-sm);
}

.hg-shadow-sm {
  box-shadow: var(--hg-shadow-sm);
}

.hg-shadow-md {
  box-shadow: var(--hg-shadow-md);
}

.hg-flex {
  display: flex;
}

.hg-flex-center {
  display: flex;
  align-items: center;
  justify-content: center;
}

.hg-stack {
  display: grid;
  gap: 16px;
}

.hg-stack-sm {
  display: grid;
  gap: 10px;
}

.hg-cluster {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.hg-sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.hg-hidden {
  display: none !important;
}

.hg-footer {
  padding: 40px 0;
  color: rgba(255, 255, 255, 0.76);
  background: var(--hg-navy);
}

.hg-footer strong {
  color: #FFFFFF;
}

@media (max-width: 940px) {
  .hg-grid-4,
  .hg-grid-3 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  body {
    font-size: 15px;
  }

  .hg-container,
  .hg-container-sm {
    width: min(100% - 28px, 1120px);
  }

  .hg-header-inner {
    min-height: 64px;
  }

  .hg-logo {
    height: 38px;
  }

  .hg-nav {
    display: none;
  }

  .hg-section,
  .hg-section-tight {
    padding: 44px 0;
  }

  .hg-hero {
    padding: 54px 0 48px;
  }

  .hg-grid-2,
  .hg-grid-3,
  .hg-grid-4 {
    grid-template-columns: 1fr;
  }
}
