/* Shared header, navigation, footer and contact dialog.
   The homepage imports this file. Blog pages link it directly.
   Edit the chrome here so marketing pages cannot drift apart. */
:root {
  --ink: #252b29;
  --muted: #67716b;
  --coral: #e96846;
  --coral-dark: #bd482b;
  --cream: #fcf9f5;
  --peach: #fae6d9;
  --mint: #e4eee4;
  --line: #e2e5df;
  --green: #325848;
  --font: "Manrope", system-ui, -apple-system, sans-serif;
}
* {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
  scroll-padding-top: 100px;
  -webkit-font-smoothing: antialiased;
}
body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  font-size: 15px;
  line-height: 1.65;
  background: #fff;
}
button,
input,
textarea {
  font: inherit;
}
button,
a {
  -webkit-tap-highlight-color: transparent;
}
a {
  color: inherit;
  text-decoration: none;
}
button {
  cursor: pointer;
}
button:disabled {
  cursor: wait;
  opacity: 0.65;
}
img {
  max-width: 100%;
  height: auto;
}
h1,
h2,
h3,
h4,
p {
  margin: 0;
}
button {
  color: inherit;
}
.icon {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex-shrink: 0;
  vertical-align: middle;
}
.icon-definitions {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}
.container {
  width: min(1280px, calc(100% - 104px));
  margin-inline: auto;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 22px;
  min-height: 52px;
  padding: 14px 24px;
  border: 1px solid var(--coral);
  border-radius: 7px;
  background: var(--coral);
  color: #fff;
  font-size: 13px;
  font-weight: 750;
  line-height: 1.5;
  transition:
    background 0.18s,
    border-color 0.18s,
    transform 0.18s;
}
.button:hover {
  background: var(--coral-dark);
  border-color: var(--coral-dark);
  transform: translateY(-2px);
}
.button .icon {
  width: 18px;
  height: 18px;
}
.button-small {
  min-height: 43px;
  padding: 10px 18px;
  gap: 20px;
  font-size: 12px;
}
.button-outline {
  border-color: #b9bcb1;
  background: transparent;
  color: var(--ink);
}
.button-outline:hover {
  background: #fff;
  border-color: var(--ink);
}
.button-light {
  background: #fff7ee;
  color: var(--ink);
  border-color: #fff7ee;
}
.button-light:hover {
  background: var(--peach);
  border-color: var(--peach);
}
.text-link {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--ink);
  font-size: 13px;
  font-weight: 800;
  border: 0;
  background: none;
  padding: 0 0 5px;
  border-bottom: 1px solid #b1b6ae;
}
.text-link .icon {
  width: 19px;
  height: 19px;
}
.text-link:hover {
  color: var(--coral-dark);
  border-color: var(--coral-dark);
}
:focus-visible {
  outline: 3px solid #377c5f;
  outline-offset: 5px;
}
.skip-link {
  position: fixed;
  z-index: 1000;
  left: 20px;
  top: -70px;
  background: #fff;
  padding: 10px 20px;
  border: 2px solid var(--green);
}
.skip-link:focus {
  top: 10px;
}
[hidden] {
  display: none !important;
}
/* Navigation */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.97);
  border-bottom: 1px solid #eeeee8;
}
.nav {
  height: 88px;
  display: flex;
  align-items: center;
  gap: 62px;
}
.brand {
  flex-shrink: 0;
  line-height: 0;
}
.brand img {
  width: 137px;
  height: 35px;
  object-fit: contain;
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
}
.nav-links a,
.login-link {
  font-size: 13px;
  font-weight: 650;
  transition: color 0.2s;
  white-space: nowrap;
}
.nav-links a:hover,
.login-link:hover {
  color: var(--coral-dark);
}
.nav-actions {
  margin-left: auto;
  display: flex;
  gap: 27px;
  align-items: center;
}
.menu-toggle {
  display: none;
  width: 40px;
  height: 40px;
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 10px;
}
.menu-toggle span {
  display: block;
  height: 2px;
  background: var(--ink);
  margin: 5px 0;
}
.mobile-signin {
  display: none;
}

/* Footer */
.site-footer {
  background: #232f28;
  color: #d7ddd2;
  padding: 57px 0 24px;
}
.footer-main {
  display: flex;
  justify-content: space-between;
  gap: 90px;
  padding-bottom: 52px;
}
.footer-brand img {
  width: 132px;
  height: 34px;
  object-fit: contain;
}
.footer-brand p {
  font-size: 18px;
  line-height: 1.55;
  font-weight: 500;
  letter-spacing: -0.3px;
  margin: 20px 0;
  color: #edf0e9;
}
.footer-brand > a:last-child {
  font-size: 10px;
  color: #b1beab;
}
.footer-brand > a:last-child span {
  margin-left: 9px;
}
.footer-links {
  display: flex;
  gap: 95px;
  padding: 5px 15px 0 0;
}
.footer-links > div {
  display: flex;
  flex-direction: column;
  gap: 11px;
}
.footer-links h2 {
  font-size: 10px;
  font-weight: 700;
  color: #f4f5ef;
  margin-bottom: 9px;
}
.footer-links a,
.footer-links button {
  font-size: 10px;
  color: #b1beab;
}
.footer-links button {
  border: 0;
  background: none;
  padding: 0;
  text-align: left;
}
.footer-links a:hover,
.footer-links button:hover,
.footer-bottom a:hover {
  color: #fff;
  text-decoration: underline;
}
.footer-bottom {
  border-top: 1px solid #ffffff13;
  padding-top: 23px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  color: #96a28e;
  font-size: 8px;
}
.footer-bottom > div {
  display: flex;
  gap: 22px;
}
/* Contact dialog */
.contact-modal {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: #1b2d27a6;
  backdrop-filter: blur(5px);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.contact-modal.open {
  display: flex;
}
.contact-dialog {
  background: #fff;
  border-radius: 13px;
  width: min(550px, 100%);
  max-height: calc(100dvh - 48px);
  overflow: auto;
  box-shadow: 0 20px 70px #10251a30;
}
.contact-head {
  padding: 27px 29px 20px;
  display: flex;
  gap: 24px;
  border-bottom: 1px solid var(--line);
}
.contact-head h2 {
  font-size: 26px;
  letter-spacing: -1px;
  margin-bottom: 8px;
}
.contact-head p {
  font-size: 12px;
  color: var(--muted);
}
.contact-close {
  margin-left: auto;
  width: 33px;
  height: 33px;
  flex-shrink: 0;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
}
.contact-close svg {
  width: 13px;
  height: 13px;
  stroke: currentColor;
  stroke-width: 2;
}
.contact-form {
  padding: 22px 29px 29px;
  display: grid;
  gap: 14px;
}
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 13px;
}
.contact-field {
  display: grid;
  gap: 5px;
}
.contact-field label {
  font-size: 11px;
  font-weight: 700;
}
.contact-field input,
.contact-field textarea {
  width: 100%;
  border: 1px solid #dce1d6;
  border-radius: 5px;
  padding: 10px 12px;
  font-size: 12px;
  color: var(--ink);
}
.contact-field textarea {
  min-height: 105px;
  resize: vertical;
}
.contact-hidden {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}
.contact-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
}
.contact-status {
  font-size: 11px;
  color: var(--muted);
}
.contact-status.ok {
  color: #3b6950;
}
.contact-status.err {
  color: #b3402f;
}
.contact-submit {
  min-width: 135px;
  font-size: 12px;
}

@media (max-width: 1150px) {
  .container {
    width: calc(100% - 64px);
  }
  .nav {
    gap: 34px;
  }
  .nav-links {
    gap: 20px;
  }
  .nav-actions {
    gap: 20px;
  }
}

@media (max-width: 950px) {
  .nav {
    height: 77px;
    gap: 28px;
  }
  .brand img {
    width: 115px;
  }
  .nav-links {
    gap: 15px;
  }
  .nav-links a,
  .login-link {
    font-size: 11px;
  }
  .nav-actions {
    gap: 16px;
  }
  .nav-actions .button {
    font-size: 10px;
    gap: 10px;
    padding-inline: 12px;
  }
  .footer-links {
    gap: 55px;
  }
  .footer-bottom > span:last-child {
    display: none;
  }
}

@media (max-width: 760px) {
  html {
    scroll-padding-top: 90px;
  }
  .container {
    width: calc(100% - 40px);
  }
  .nav {
    height: 72px;
    gap: 0;
  }
  .brand img {
    width: 119px;
    height: 31px;
  }
  .nav-actions {
    gap: 12px;
  }
  .login-link {
    display: none;
  }
  .nav-actions .button {
    font-size: 11px;
    min-height: 39px;
    padding: 8px 13px;
    gap: 9px;
  }
  .nav-actions .button .icon {
    width: 15px;
    height: 15px;
  }
  .menu-toggle {
    display: block;
  }
  .nav-links {
    display: none;
    position: absolute;
    left: 0;
    right: 0;
    top: 72px;
    background: #fff;
    border-bottom: 1px solid var(--line);
    box-shadow: 0 15px 20px #22311b0b;
    padding: 12px 20px 20px;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
  }
  .nav-links.is-open {
    display: flex;
  }
  .nav-links a {
    font-size: 14px;
    padding: 12px;
    border-radius: 5px;
  }
  .nav-links a:hover {
    background: var(--cream);
  }
  .mobile-signin {
    display: block;
  }
  .site-footer {
    padding-top: 43px;
  }
  .footer-main {
    flex-direction: column;
    gap: 34px;
    padding-bottom: 35px;
  }
  .footer-brand p {
    font-size: 20px;
  }
  .footer-links {
    gap: 65px;
    justify-content: flex-start;
    padding-right: 0;
  }
  .footer-links h2 {
    font-size: 11px;
  }
  .footer-links a,
  .footer-links button {
    font-size: 11px;
  }
  .footer-bottom {
    align-items: flex-start;
    flex-direction: column;
    gap: 14px;
    font-size: 9px;
  }
  .footer-bottom > div {
    gap: 25px;
  }
  .contact-modal {
    padding: 16px;
  }
  .contact-dialog {
    max-height: calc(100dvh - 32px);
  }
  .contact-head {
    padding: 23px 22px 18px;
  }
  .contact-form {
    padding: 20px 22px 24px;
  }
  .contact-actions {
    flex-wrap: wrap;
  }
  .contact-submit {
    margin-left: auto;
  }
}

@media (max-width: 390px) {
  .container {
    width: calc(100% - 32px);
  }
  .nav-actions {
    gap: 8px;
  }
  .brand img {
    width: 105px;
  }
  .nav-actions .button {
    font-size: 10px;
    padding-inline: 10px;
  }
  .nav-actions .button .icon {
    display: none;
  }
  .footer-links {
    gap: 40px;
  }
  .contact-grid {
    grid-template-columns: 1fr;
  }
}

/* Homepage only: frosted pill. Blog pages keep the full-width bar. */
body.home .site-header {
  position: sticky;
  top: 16px;
  z-index: 80;
  width: min(1080px, calc(100% - 32px));
  margin: 16px auto 0;
  background: transparent;
  border: 0;
}
body.home .site-header .nav {
  width: 100%;
  height: 64px;
  gap: 22px;
  padding: 0 10px 0 18px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.85);
  box-shadow:
    0 1px 2px #0000000a,
    0 10px 30px -12px #0000001f;
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
}
body.home .site-header .brand img {
  width: 124px;
  height: 32px;
}
body.home .site-header .nav-links {
  gap: 22px;
}
@media (max-width: 760px) {
  body.home .site-header {
    top: 10px;
    width: calc(100% - 16px);
    margin-top: 10px;
  }
  body.home .site-header .nav {
    height: 58px;
    padding-inline: 12px 8px;
    gap: 8px;
  }
  body.home .site-header .nav-links {
    top: calc(100% + 8px);
    left: 0;
    right: 0;
    border: 1px solid #efe6e2;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.94);
    box-shadow:
      0 1px 2px #0000000a,
      0 10px 30px -12px #0000001f;
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
  }
}
@media (prefers-reduced-motion: reduce) {
  body.home .site-header .nav {
    backdrop-filter: none;
  }
}
