/* Village Knowledge Management: site styles
   Colors come from the approved brand palette. Edit the tokens below to retheme. */

@font-face {
  font-family: "Outfit";
  src: url("/assets/fonts/outfit-latin-wght-normal.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: "Source Serif 4";
  src: url("/assets/fonts/source-serif-4-latin-wght-normal.woff2") format("woff2");
  font-weight: 200 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Source Serif 4";
  src: url("/assets/fonts/source-serif-4-latin-wght-italic.woff2") format("woff2");
  font-weight: 200 900;
  font-style: italic;
  font-display: swap;
}

:root {
  --navy: #12355b;
  --teal: #1f8a8a;
  --teal-deep: #186f70; /* teal for small text on light backgrounds (5.7:1) */
  --teal-light: #7fd1d1; /* teal for text on navy (7.1:1) */
  --orange: #f28c28;
  --ink: #2c3e50;
  --paper: #f8fafc;
  --mist: #e8eef3;

  --display: "Outfit", "Segoe UI", system-ui, sans-serif;
  --text: "Source Serif 4", Georgia, "Times New Roman", serif;

  --gutter: clamp(1.25rem, 4vw, 2.5rem);
  --measure: 38rem;
  --wide: 74rem;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 6rem;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--text);
  font-size: 1.0625rem;
  line-height: 1.65;
}

img,
svg {
  max-width: 100%;
  display: block;
}

a {
  color: var(--teal-deep);
  text-decoration-thickness: 0.08em;
  text-underline-offset: 0.18em;
}
a:hover {
  color: var(--navy);
}

:focus-visible {
  outline: 3px solid var(--orange);
  outline-offset: 3px;
  border-radius: 2px;
}

.skip {
  position: absolute;
  left: 1rem;
  top: -4rem;
  background: var(--navy);
  color: var(--paper);
  padding: 0.6rem 1rem;
  z-index: 100;
  font-family: var(--display);
}
.skip:focus {
  top: 1rem;
}

.wrap {
  width: 100%;
  max-width: var(--wide);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* Type */
h1,
h2,
h3 {
  font-family: var(--display);
  color: var(--navy);
  margin: 0;
  letter-spacing: -0.015em;
  text-wrap: balance;
}
h1 {
  font-size: clamp(2.9rem, 8vw, 5.6rem);
  font-weight: 300;
  line-height: 1.02;
  letter-spacing: -0.03em;
}
h2 {
  font-size: clamp(1.95rem, 4.2vw, 3.1rem);
  font-weight: 400;
  line-height: 1.1;
}
h3 {
  font-size: 1.4rem;
  font-weight: 500;
  line-height: 1.2;
}
p {
  margin: 0 0 1.1em;
  max-width: var(--measure);
}
.lede {
  font-size: clamp(1.2rem, 2.2vw, 1.4rem);
  line-height: 1.55;
  max-width: 34rem;
}

/* Buttons */
.btn {
  display: inline-block;
  font-family: var(--display);
  font-weight: 500;
  font-size: 1.05rem;
  line-height: 1;
  text-decoration: none;
  background: var(--navy);
  color: var(--paper);
  padding: 1.05rem 1.7rem;
  border-radius: 999px;
  border: 2px solid var(--navy);
  cursor: pointer;
  transition: background-color 0.15s, color 0.15s, border-color 0.15s;
}
.btn:hover {
  background: var(--teal-deep);
  border-color: var(--teal-deep);
  color: var(--paper);
}
.btn--ondark {
  background: var(--orange);
  border-color: var(--orange);
  color: var(--navy);
}
.btn--ondark:hover {
  background: var(--paper);
  border-color: var(--paper);
  color: var(--navy);
}
.btn--quiet {
  background: transparent;
  color: var(--navy);
}
.btn--quiet:hover {
  background: var(--navy);
  border-color: var(--navy);
  color: var(--paper);
}
.btn--small {
  font-size: 0.95rem;
  padding: 0.75rem 1.25rem;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(248, 250, 252, 0.94);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--mist);
}
.site-header__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding-block: 0.7rem;
}
.brand img {
  height: 3rem;
  width: auto;
}
.site-nav {
  display: flex;
  gap: 1.75rem;
  align-items: center;
  margin-left: auto;
}
.site-nav a {
  font-family: var(--display);
  font-weight: 500;
  font-size: 0.98rem;
  color: var(--navy);
  text-decoration: none;
  padding-block: 0.4rem;
  border-bottom: 2px solid transparent;
}
.site-nav a:hover {
  border-bottom-color: var(--orange);
}
.site-header__cta {
  display: flex;
  align-items: center;
  gap: 1rem;
}
.lang {
  font-family: var(--display);
  font-size: 0.9rem;
  font-weight: 500;
}

@media (max-width: 62rem) {
  .site-header__row {
    flex-wrap: wrap;
  }
  .site-nav {
    order: 3;
    margin-left: 0;
    width: 100%;
    overflow-x: auto;
    gap: 1.4rem;
    padding-bottom: 0.2rem;
    scrollbar-width: none;
  }
  .site-nav::-webkit-scrollbar {
    display: none;
  }
  .site-nav a {
    white-space: nowrap;
  }
}
@media (max-width: 30rem) {
  .brand img {
    height: 2.5rem;
  }
  .btn--small {
    padding: 0.65rem 1rem;
    font-size: 0.9rem;
  }
}

/* Sections */
.section {
  padding-block: clamp(4rem, 9vw, 7.5rem);
}
.section--tight {
  padding-block: clamp(3rem, 6vw, 5rem);
}
.section--mist {
  background: var(--mist);
}
.section--navy {
  background: var(--navy);
  color: var(--paper);
}
.section--navy h2,
.section--navy h3 {
  color: var(--paper);
}
.section--navy a {
  color: var(--teal-light);
}
.section--navy a:hover {
  color: var(--paper);
}
.section__head {
  margin-bottom: clamp(2rem, 5vw, 3.5rem);
  max-width: 46rem;
}

/* Hero */
.hero {
  padding-block: clamp(3rem, 8vw, 6.5rem) clamp(3.5rem, 8vw, 6rem);
  overflow: hidden;
}
.hero__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.75fr);
  gap: clamp(2rem, 5vw, 5rem);
  align-items: center;
}
.hero h1 {
  margin-bottom: 1.6rem;
}
.hero__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem 1.5rem;
  margin-top: 2.2rem;
}
.hero__note {
  margin-top: 2.5rem;
  font-size: 0.98rem;
  color: var(--ink);
  max-width: 30rem;
}
.hero__mark {
  width: min(100%, 24rem);
  justify-self: center;
}
@media (max-width: 52rem) {
  .hero__grid {
    grid-template-columns: 1fr;
  }
  .hero__mark {
    order: -1;
    width: 9.5rem;
    justify-self: start;
  }
}

/* The mark draws itself once on load: the open circle closes. */
.mark path {
  fill: none;
  stroke-width: 54;
  stroke-linecap: butt;
}
.mark .mark__teal {
  stroke: var(--teal);
}
.mark .mark__orange {
  stroke: var(--orange);
}
@media (prefers-reduced-motion: no-preference) {
  .mark path {
    stroke-dasharray: 1;
    stroke-dashoffset: 1;
    animation: draw 1.1s cubic-bezier(0.55, 0.1, 0.25, 1) forwards;
  }
  .mark .mark__orange {
    animation-delay: 1s;
    animation-duration: 0.8s;
  }
}
@keyframes draw {
  to {
    stroke-dashoffset: 0;
  }
}

/* Problem */
.problem__grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(2rem, 6vw, 6rem);
  align-items: start;
}
.problem__lead p {
  font-size: 1.25rem;
  color: #dbe6f0;
  margin-top: 1.5rem;
}
.signs {
  list-style: none;
  margin: 0;
  padding: 0;
}
.signs li {
  font-family: var(--display);
  font-size: clamp(1.3rem, 2.4vw, 1.75rem);
  font-weight: 300;
  line-height: 1.3;
  padding-block: 1.25rem;
  border-top: 1px solid rgba(248, 250, 252, 0.22);
}
.signs li:last-child {
  border-bottom: 1px solid rgba(248, 250, 252, 0.22);
}
@media (max-width: 52rem) {
  .problem__grid {
    grid-template-columns: 1fr;
  }
}

/* Services */
.rows {
  margin: 0;
  padding: 0;
  list-style: none;
}
.row {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.6fr);
  gap: 1rem clamp(2rem, 6vw, 6rem);
  padding-block: 2rem;
  border-top: 2px solid var(--navy);
}
.row:last-child {
  border-bottom: 2px solid var(--navy);
}
.row p:last-child {
  margin-bottom: 0;
}
@media (max-width: 52rem) {
  .row {
    grid-template-columns: 1fr;
  }
}

.stance {
  margin-top: clamp(2.5rem, 6vw, 4rem);
  padding: clamp(1.5rem, 4vw, 2.5rem);
  background: var(--mist);
  border-left: 6px solid var(--orange);
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.6fr);
  gap: 1rem clamp(2rem, 6vw, 6rem);
}
.stance p:last-child {
  margin-bottom: 0;
}
@media (max-width: 52rem) {
  .stance {
    grid-template-columns: 1fr;
  }
}

/* Who */
.who {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(2rem, 6vw, 6rem);
}
@media (max-width: 52rem) {
  .who {
    grid-template-columns: 1fr;
  }
}

/* Results */
.work-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.work-row {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.6fr);
  gap: 0.5rem clamp(2rem, 6vw, 6rem);
  padding-block: 1.9rem;
  border-top: 1px solid rgba(18, 53, 91, 0.25);
  text-decoration: none;
  color: var(--ink);
}
.work-list li:last-child .work-row {
  border-bottom: 1px solid rgba(18, 53, 91, 0.25);
}
.work-row h3 {
  font-size: clamp(1.5rem, 3vw, 2.1rem);
  font-weight: 400;
}
.work-row p {
  margin: 0 0 0.6rem;
}
.work-row__more {
  font-family: var(--display);
  font-weight: 500;
  color: var(--teal-deep);
  text-decoration: underline;
  text-decoration-thickness: 0.08em;
  text-underline-offset: 0.2em;
}
.work-row:hover {
  background: rgba(31, 138, 138, 0.07);
  color: var(--ink);
}
.work-row:hover .work-row__more {
  color: var(--navy);
}
@media (max-width: 52rem) {
  .work-row {
    grid-template-columns: 1fr;
  }
}

/* Principles */
.principles {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 clamp(2rem, 6vw, 6rem);
  margin: 0;
}
.principles div {
  padding-block: 1.4rem;
  border-top: 1px solid rgba(18, 53, 91, 0.25);
}
.principles dt {
  font-family: var(--display);
  font-weight: 500;
  font-size: 1.3rem;
  color: var(--navy);
}
.principles dd {
  margin: 0.3rem 0 0;
}
.values {
  margin-top: 2rem;
  font-family: var(--display);
  font-size: 1.15rem;
  color: var(--navy);
}
@media (max-width: 52rem) {
  .principles {
    grid-template-columns: 1fr;
  }
}

/* About */
.about {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.4fr);
  gap: clamp(2rem, 6vw, 6rem);
  align-items: center;
}
.arch {
  width: min(100%, 22rem);
  aspect-ratio: 3 / 4;
  border-radius: 999px 999px 0 0;
  overflow: hidden;
  background: var(--mist);
  border-bottom: 8px solid var(--teal);
}
.arch img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 30%;
}
.about__caption {
  font-family: var(--display);
  font-size: 0.95rem;
  margin-top: 0.8rem;
}
@media (max-width: 52rem) {
  .about {
    grid-template-columns: 1fr;
  }
  .arch {
    width: min(100%, 18rem);
  }
}

/* Thinking */
.posts {
  list-style: none;
  margin: 0;
  padding: 0;
}
.posts li {
  padding-block: 1.3rem;
  border-top: 1px solid rgba(18, 53, 91, 0.25);
}
.posts li:last-child {
  border-bottom: 1px solid rgba(18, 53, 91, 0.25);
}
.posts a {
  font-family: var(--display);
  font-size: 1.45rem;
  font-weight: 400;
  color: var(--navy);
  text-decoration: none;
}
.posts a:hover {
  text-decoration: underline;
}
.posts time,
.post-meta {
  display: block;
  font-family: var(--display);
  font-size: 0.92rem;
  color: var(--ink);
  margin-top: 0.2rem;
}
.empty {
  font-size: 1.1rem;
}

/* Contact */
.contact__grid {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.2fr);
  gap: clamp(2rem, 6vw, 5rem);
  align-items: start;
}
.contact__links {
  list-style: none;
  padding: 0;
  margin: 2rem 0 0;
  display: grid;
  gap: 0.7rem;
}
.embed {
  background: var(--paper);
  color: var(--ink);
  border-radius: 1rem;
  overflow: hidden;
  min-height: 12rem;
}
.embed__fallback {
  padding: clamp(1.5rem, 4vw, 2.2rem);
}
.embed__fallback p {
  margin-bottom: 1rem;
}
.embed__fallback a:not(.btn) {
  color: var(--teal-deep);
}
.embed iframe {
  width: 100%;
  min-height: 700px;
  border: 0;
  display: block;
}
.calendly-inline-widget {
  min-width: 100%;
  height: 700px;
}
@media (max-width: 52rem) {
  .contact__grid {
    grid-template-columns: 1fr;
  }
}

/* Case study and article pages */
.page {
  padding-block: clamp(3rem, 7vw, 5.5rem);
}
.page__back {
  font-family: var(--display);
  font-weight: 500;
  display: inline-block;
  margin-bottom: 2rem;
}
.page h1 {
  font-size: clamp(2.3rem, 6vw, 4rem);
  margin-bottom: 1.2rem;
}
.facts {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.6fr);
  gap: 2.5rem clamp(2rem, 6vw, 6rem);
  margin-top: clamp(2.5rem, 6vw, 4rem);
}
.facts h2 {
  font-size: 1.6rem;
  font-weight: 500;
}
.facts ul {
  margin: 0;
  padding-left: 1.2rem;
  max-width: var(--measure);
}
.facts li {
  margin-bottom: 0.5rem;
}
.facts p {
  margin: 0;
}
@media (max-width: 52rem) {
  .facts {
    grid-template-columns: 1fr;
    gap: 0.6rem;
  }
  .facts h2 {
    margin-top: 1.5rem;
  }
}
.quote {
  margin: clamp(2.5rem, 6vw, 4rem) 0 0;
  padding: clamp(1.5rem, 4vw, 2.5rem);
  background: var(--mist);
  border-left: 6px solid var(--teal);
}
.quote p {
  font-size: 1.15rem;
  max-width: 44rem;
}
.quote footer {
  font-family: var(--display);
  color: var(--navy);
  font-weight: 500;
}
.quote footer span {
  display: block;
  font-weight: 400;
  color: var(--ink);
}
.prose {
  max-width: var(--measure);
}
.prose h2 {
  font-size: 1.9rem;
  margin: 2.2rem 0 0.8rem;
}
.prose h3 {
  margin: 1.8rem 0 0.6rem;
}
.prose li {
  margin-bottom: 0.4rem;
}
.prose img {
  height: auto;
  margin-block: 1.5rem;
}
.draft-note {
  background: #fff3e0;
  border-left: 6px solid var(--orange);
  padding: 1rem 1.2rem;
  font-family: var(--display);
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--mist);
  padding-block: 3rem;
  font-size: 0.98rem;
}
.site-footer__row {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 1.5rem;
}
.site-footer img {
  height: 2.8rem;
  width: auto;
}
.site-footer ul {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  margin: 0;
  padding: 0;
}
.linklike {
  background: none;
  border: 0;
  padding: 0;
  font: inherit;
  color: var(--teal-deep);
  text-decoration: underline;
  text-decoration-thickness: 0.08em;
  text-underline-offset: 0.18em;
  cursor: pointer;
}
.linklike:hover {
  color: var(--navy);
}
.copyright {
  width: 100%;
  margin: 0;
  max-width: none;
  font-size: 0.9rem;
}

/* Cookie banner */
.consent {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 60;
  background: var(--paper);
  border-top: 4px solid var(--teal);
  box-shadow: 0 -8px 30px rgba(18, 53, 91, 0.14);
  padding: 1.1rem 0;
}
.consent[hidden] {
  display: none;
}
.consent__row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem 2rem;
}
.consent p {
  margin: 0;
  font-size: 0.98rem;
  line-height: 1.5;
  max-width: 44rem;
}
.consent__actions {
  display: flex;
  gap: 0.7rem;
  flex-wrap: wrap;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}
