:root {
  --ink: #12212b;
  --ink-soft: #3a4a55;
  --paper: #e9eef2;
  --paper-2: #f7fafc;
  --line: rgba(18, 33, 43, 0.12);
  --teal: #0f6e6a;
  --teal-deep: #0a4f4c;
  --sand: #d8c3a5;
  --glow-safe: transparent;
  --font-display: "Syne", sans-serif;
  --font-body: "Manrope", sans-serif;
  --radius: 14px;
  
  --header-h: 72px;
}

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

html {
  scroll-behavior: smooth;
}

.home-page {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font: inherit;
  color: inherit;
  background: none;
  border: 0;
  cursor: pointer;
}

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

.page-bg {
  position: fixed;
  inset: 0;
  z-index: -2;
  background:
    radial-gradient(1200px 600px at 85% -10%, rgba(15, 110, 106, 0.16), transparent 60%),
    radial-gradient(900px 500px at -10% 30%, rgba(216, 195, 165, 0.28), transparent 55%),
    linear-gradient(180deg, #eef3f6 0%, #e5ebf0 45%, #dde6ea 100%);
}

.page-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0.35;
  background-image:
    linear-gradient(rgba(18, 33, 43, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(18, 33, 43, 0.04) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.7), transparent 85%);
}

.home-page .container {
  width: min(1180px, calc(100% - 2.5rem));
  margin-inline: auto;
}
.shell-unused {
  width: min(1180px, calc(100% - 2.5rem));
  margin-inline: auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  height: var(--header-h);
  backdrop-filter: blur(14px);
  background: rgba(233, 238, 242, 0.78);
  border-bottom: 1px solid var(--line);
}

.home-page .header-inner, .header-row {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.home-page .logo {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.35rem;
  letter-spacing: -0.03em;
  color: var(--ink);
  text-decoration: none;
  max-width: none;
}
.home-page .logo:hover { text-decoration: none; }
.home-page .logo span { color: var(--teal); }

.nav {
  display: flex;
  align-items: center;
  gap: 1.4rem;
}

.nav a {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--ink-soft);
  transition: color 0.2s ease;
}

.nav a:hover {
  color: var(--ink);
}

.home-page .nav a.nav-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  margin-left: 0.25rem;
  padding: 0.8rem 1.25rem;
  border: 1px solid transparent;
  border-radius: 999px;
  background: var(--ink);
  color: #f4f7f8 !important;
  font-weight: 700;
  font-size: 0.95rem;
  white-space: nowrap;
  transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.home-page .nav a.nav-cta:hover {
  background: var(--teal-deep);
  color: #f4f7f8 !important;
  transform: translateY(-1px);
  text-decoration: none;
}

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  place-items: center;
  gap: 6px;
  flex-direction: column;
}

.nav-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  background: var(--ink);
}

.home-hero {
  position: relative;
  min-height: calc(100vh - var(--header-h));
  display: grid;
  align-items: end;
  padding: 4rem 0 5rem;
  overflow: clip;
}

.home-hero .hero-plane {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero-plane-grid {
  position: absolute;
  inset: 8% 4% 18% 38%;
  border: 1px solid rgba(18, 33, 43, 0.08);
  background:
    linear-gradient(135deg, rgba(15, 110, 106, 0.12), rgba(216, 195, 165, 0.18)),
    repeating-linear-gradient(
      -18deg,
      transparent,
      transparent 18px,
      rgba(18, 33, 43, 0.035) 18px,
      rgba(18, 33, 43, 0.035) 19px
    );
  border-radius: 28px;
  transform: rotate(-1.5deg);
  animation: plane-drift 12s ease-in-out infinite alternate;
}

.hero-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(8px);
}

.hero-orb--a {
  width: 280px;
  height: 280px;
  right: 12%;
  top: 18%;
  background: rgba(15, 110, 106, 0.22);
  animation: float-a 9s ease-in-out infinite;
}

.hero-orb--b {
  width: 180px;
  height: 180px;
  right: 28%;
  bottom: 22%;
  background: rgba(216, 195, 165, 0.45);
  animation: float-b 11s ease-in-out infinite;
}

.hero-lines {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0.55;
}

.draw-line {
  fill: none;
  stroke: var(--teal-deep);
  stroke-width: 1.4;
  stroke-linecap: round;
  stroke-dasharray: 1200;
  stroke-dashoffset: 1200;
  animation: draw 2.4s ease forwards 0.3s;
}

.draw-line--delay {
  stroke: rgba(18, 33, 43, 0.35);
  animation-delay: 0.7s;
}

.node {
  fill: var(--teal);
  opacity: 0;
  animation: node-in 0.6s ease forwards 1.6s;
}

.node--delay {
  animation-delay: 1.9s;
}

.home-hero .hero-copy {
  position: relative;
  z-index: 1;
  max-width: 720px;
}

.brand-mark {
  margin: 0 0 1rem;
  font-family: var(--font-display);
  font-size: clamp(2.8rem, 8vw, 5.4rem);
  font-weight: 800;
  letter-spacing: -0.05em;
  line-height: 0.92;
  color: var(--ink);
}

.home-hero h1 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 4.4vw, 3rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.08;
}

.home-hero .hero-lead {
  margin: 1.25rem 0 0;
  max-width: 34rem;
  font-size: 1.08rem;
  color: var(--ink-soft);
}

.home-hero .hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  margin-top: 2rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0.8rem 1.25rem;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.95rem;
  transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn-primary {
  background: var(--ink);
  color: #f4f7f8;
}

.btn-primary:hover {
  background: var(--teal-deep);
}

.btn-ghost {
  border: 1px solid rgba(18, 33, 43, 0.28);
  background: rgba(247, 250, 252, 0.55);
}

.btn-ghost:hover {
  border-color: var(--ink);
}

.home-section {
  padding: 5.5rem 0;
}

.home-section .section-head {
  max-width: 40rem;
  margin-bottom: 2.4rem;
}

.home-section .section-head--row {
  max-width: none;
  display: grid;
  grid-template-columns: 1.3fr 0.9fr;
  gap: 1.5rem;
  align-items: end;
}

.home-section .eyebrow, .contact-panel .eyebrow {
  margin: 0 0 0.7rem;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--teal-deep);
}

.home-section h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(1.7rem, 3.2vw, 2.45rem);
  letter-spacing: -0.03em;
  line-height: 1.12;
}

.home-section .section-note {
  margin: 0;
  color: var(--ink-soft);
  max-width: 28rem;
}

.capability-list {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
}

.capability {
  padding: 1.35rem 1.2rem 1.5rem;
  border-top: 2px solid var(--ink);
}

.capability h3 {
  margin: 0 0 0.65rem;
  font-family: var(--font-display);
  font-size: 1.15rem;
  letter-spacing: -0.02em;
}

.capability p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.96rem;
}

.filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  margin-bottom: 1.6rem;
}

.filter-btn {
  min-height: 40px;
  padding: 0.45rem 0.9rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(247, 250, 252, 0.7);
  font-weight: 600;
  font-size: 0.88rem;
  color: var(--ink-soft);
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.filter-btn:hover,
.filter-btn.is-active {
  background: var(--ink);
  border-color: var(--ink);
  color: #f4f7f8;
}

.project-list {
  display: grid;
  gap: 0.75rem;
}

.project-item {
  width: 100%;
  text-align: left;
  display: grid;
  grid-template-columns: 1.4fr 1.1fr auto;
  gap: 1rem;
  align-items: center;
  padding: 1.15rem 1.1rem;
  border: 1px solid transparent;
  border-bottom: 1px solid var(--line);
  border-radius: 12px;
  transition: background 0.25s ease, border-color 0.25s ease, transform 0.25s ease, opacity 0.25s ease;
}

.project-item:hover {
  background: rgba(247, 250, 252, 0.8);
  border-color: var(--line);
  transform: translateX(4px);
}

.project-item.is-hidden {
  display: none;
}

.project-item h3 {
  margin: 0 0 0.35rem;
  font-family: var(--font-display);
  font-size: 1.2rem;
  letter-spacing: -0.02em;
}

.project-item .meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--teal-deep);
}

.project-item .short {
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.95rem;
}

.project-item .open-label {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--ink);
  white-space: nowrap;
}

.process-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.2rem;
}

.process-list li {
  padding: 1.4rem 1.2rem;
  border-left: 2px solid var(--teal);
  background: linear-gradient(180deg, rgba(247, 250, 252, 0.75), rgba(247, 250, 252, 0.2));
}

.process-list .step {
  display: block;
  margin-bottom: 1rem;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 0.95rem;
  letter-spacing: 0.08em;
  color: var(--teal-deep);
}

.process-list h3 {
  margin: 0 0 0.55rem;
  font-family: var(--font-display);
  font-size: 1.2rem;
}

.process-list p {
  margin: 0;
  color: var(--ink-soft);
}

.contact {
  padding-bottom: 6rem;
}

.contact-panel {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 2rem;
  padding: 2.4rem;
  border-radius: 24px;
  background:
    linear-gradient(135deg, rgba(15, 110, 106, 0.12), rgba(216, 195, 165, 0.22)),
    var(--paper-2);
  border: 1px solid var(--line);
}

.contact-lead {
  margin: 1rem 0 0;
  max-width: 34rem;
  color: var(--ink-soft);
  font-size: 1.05rem;
}

.contact-links {
  display: grid;
  gap: 0.7rem;
  align-content: center;
}

.contact-link {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.95rem 1rem;
  border-radius: 12px;
  background: rgba(247, 250, 252, 0.85);
  border: 1px solid var(--line);
  font-weight: 600;
  transition: border-color 0.2s ease, transform 0.2s ease;
}

.contact-link:hover {
  border-color: var(--ink);
  transform: translateY(-1px);
}

.contact-link span:last-child {
  color: var(--teal-deep);
  font-weight: 700;
}

.home-page .site-footer {
  border-top: 1px solid var(--line);
  padding: 1.4rem 0 2rem;
  background: transparent;
}
.home-page .footer-inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1rem;
  align-items: center;
  color: var(--ink-soft);
  font-size: 0.9rem;
  padding: 0;
}
.home-page .footer-copy { margin: 0; }
.home-page .footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
}
.home-page .footer-links a {
  color: var(--ink-soft);
  text-decoration: none;
  font-weight: 600;
}
.home-page .footer-links a:hover { color: var(--ink); }
.home-page .logo--footer { font-size: 1.05rem; }

.footer-row-unused {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: center;
  color: var(--ink-soft);
  font-size: 0.9rem;
}

.brand-footer-unused {
  font-size: 1.05rem;
}

.project-dialog {
  width: min(760px, calc(100% - 2rem));
  max-height: min(86vh, 900px);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 0;
  background: var(--paper-2);
  color: var(--ink);
  box-shadow: 0 24px 60px rgba(18, 33, 43, 0.18);
}

.project-dialog::backdrop {
  background: rgba(18, 33, 43, 0.42);
  backdrop-filter: blur(3px);
}

.dialog-bar {
  display: flex;
  justify-content: flex-end;
  padding: 0.85rem 1rem 0;
}

.dialog-close {
  font-weight: 700;
  color: var(--ink-soft);
}

.dialog-body {
  padding: 0.4rem 1.4rem 1.6rem;
  overflow: auto;
}

.dialog-body .meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 0.8rem;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--teal-deep);
}

.dialog-body h2 {
  margin: 0 0 0.8rem;
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 3vw, 2rem);
  letter-spacing: -0.03em;
}

.dialog-body .desc {
  white-space: pre-line;
  color: var(--ink-soft);
}

.dialog-body h3 {
  margin: 1.3rem 0 0.55rem;
  font-family: var(--font-display);
  font-size: 1.05rem;
}

.dialog-body ul {
  margin: 0;
  padding-left: 1.1rem;
  color: var(--ink-soft);
}

.dialog-body li + li {
  margin-top: 0.3rem;
}

.stack-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.stack-chip {
  padding: 0.3rem 0.6rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--ink-soft);
}

.live-link {
  display: inline-flex;
  margin-top: 1.2rem;
  font-weight: 700;
  color: var(--teal-deep);
  border-bottom: 1px solid currentColor;
}

.reveal {
  opacity: 0;
  transform: translateY(16px);
  animation: rise 0.8s ease forwards;
}

.reveal-delay-1 { animation-delay: 0.12s; }
.reveal-delay-2 { animation-delay: 0.24s; }
.reveal-delay-3 { animation-delay: 0.36s; }

@keyframes rise {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes draw {
  to { stroke-dashoffset: 0; }
}

@keyframes node-in {
  to { opacity: 1; }
}

@keyframes plane-drift {
  from { transform: rotate(-1.5deg) translateY(0); }
  to { transform: rotate(-0.5deg) translateY(-8px); }
}

@keyframes float-a {
  from { transform: translateY(0); }
  to { transform: translateY(18px); }
}

@keyframes float-b {
  from { transform: translateY(0) translateX(0); }
  to { transform: translateY(-14px) translateX(10px); }
}

@media (max-width: 960px) {
  .capability-list,
  .process-list,
  .section-head--row,
  .contact-panel {
    grid-template-columns: 1fr;
  }

  .project-item {
    grid-template-columns: 1fr;
    gap: 0.55rem;
  }

  .project-item .open-label {
    justify-self: start;
  }

  .hero-plane-grid {
    inset: 12% 6% 42% 6%;
  }
}

@media (max-width: 760px) {
  :root {
    --shell: min(1180px, calc(100% - 1.4rem));
  }

  .nav-toggle {
    display: grid;
  }

  .nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    bottom: auto;
    z-index: 50;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 0.6rem 1rem 1rem;
    background: rgba(233, 238, 242, 0.96);
    border-bottom: 1px solid var(--line);
  }

  .nav.open, .nav.is-open {
    display: flex;
  }

  .nav a {
    padding: 0.85rem 0.2rem;
    border-bottom: 1px solid var(--line);
  }

  .home-page .nav a.nav-cta {
    margin-top: 0.75rem;
    margin-left: 0;
    width: 100%;
    border-bottom: 0;
    text-align: center;
  }

  .home-hero {
    min-height: auto;
    padding: 3rem 0 3.5rem;
  }

  .brand-mark {
    font-size: clamp(2.4rem, 14vw, 3.6rem);
  }

  .footer-row-unused {
    flex-direction: column;
    align-items: flex-start;
  }
}


/* Products teaser on homepage */
.home-products {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
}
.home-product {
  display: block;
  padding: 1.4rem 1.25rem;
  border-top: 2px solid var(--ink);
  text-decoration: none;
  color: inherit;
  transition: background 0.2s ease, transform 0.2s ease;
}
.home-product:hover {
  background: rgba(247, 250, 252, 0.8);
  transform: translateY(-2px);
  text-decoration: none;
}
.home-product h3 {
  margin: 0 0 0.55rem;
  font-family: var(--font-display);
  font-size: 1.2rem;
  letter-spacing: -0.02em;
}
.home-product p {
  margin: 0 0 0.9rem;
  color: var(--ink-soft);
}
.home-product span {
  font-weight: 700;
  color: var(--teal-deep);
}
@media (max-width: 760px) {
  .home-products { grid-template-columns: 1fr; }
  .home-page .container { width: min(1180px, calc(100% - 1.4rem)); }
}

/* Homepage header uses new look */
.home-page .site-header {
  background: rgba(233, 238, 242, 0.78);
  border-bottom: 1px solid var(--line);
}
.home-page .nav a {
  text-decoration: none;
  position: static;
}
.home-page .nav a::after {
  display: none;
}
.home-page .nav a:hover {
  text-decoration: none;
}
.home-page a.btn:hover {
  text-decoration: none;
}
.home-page .btn-primary {
  background: var(--ink);
  color: #f4f7f8;
}
.home-page .btn-primary:hover {
  background: var(--teal-deep);
}
.home-page .home-hero {
  background: transparent;
  border-bottom: 0;
  padding: 4rem 0 5rem;
}

@media (max-width: 1100px) {
  /* Absolute under sticky header — avoids backdrop-filter creating a
     fixed containing block that clips/offsets the drawer. Do not use
     inset: auto here; it resets top/left/right and collapses the menu. */
  .home-page .site-header {
    overflow: visible;
  }
  .home-page .nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    bottom: auto;
    width: auto;
    z-index: 50;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 0.6rem 1rem 1rem;
    background: #e9eef2;
    border-bottom: 1px solid var(--line);
    box-shadow: 0 12px 28px rgba(20, 36, 44, 0.08);
    transform: none;
    opacity: 1;
    pointer-events: auto;
  }
  .home-page .nav.open {
    display: flex;
    transform: none;
    opacity: 1;
  }
  .home-page .nav a {
    padding: 0.85rem 0.2rem;
    border-bottom: 1px solid var(--line);
  }
  .home-page .nav a.nav-cta {
    margin-top: 0.75rem;
    margin-left: 0;
    width: 100%;
    padding: 0.8rem 1.25rem;
    border-bottom: 0;
    text-align: center;
  }
  .home-page .nav-toggle {
    display: grid;
  }
}
