:root {
  color-scheme: light;
  --bg: #ffffff;
  --bg-soft: #f6f8fb;
  --bg-muted: #edf2f7;
  --ink: #111827;
  --ink-soft: #374151;
  --muted: #64748b;
  --line: #d9e2ec;
  --accent: #0f766e;
  --accent-strong: #0b5f59;
  --accent-cool: #0369a1;
  --accent-hot: #be123c;
  --shadow: 0 22px 60px rgba(15, 23, 42, 0.12);
  --max: 1180px;
  --header: 76px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.6;
  text-rendering: optimizeLegibility;
}

body.is-scrolled .site-header {
  box-shadow: 0 14px 34px rgba(15, 23, 42, 0.08);
}

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

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

button,
input,
textarea {
  font: inherit;
}

.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 100;
  transform: translateY(-160%);
  border-radius: 8px;
  background: var(--ink);
  color: #ffffff;
  padding: 10px 14px;
}

.skip-link:focus {
  transform: translateY(0);
}

.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 90;
  width: 100%;
  height: 3px;
  background: transparent;
  pointer-events: none;
}

.scroll-progress span {
  display: block;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, var(--accent), var(--accent-cool), var(--accent-hot));
  transform: scaleX(0);
  transform-origin: left center;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.88);
  border-bottom: 1px solid rgba(217, 226, 236, 0.8);
  backdrop-filter: blur(18px);
}

.nav-shell {
  width: min(100% - 40px, var(--max));
  min-height: var(--header);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: max-content;
  font-weight: 760;
}

.brand-mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: var(--ink);
  color: #ffffff;
  line-height: 1;
}

.brand-text {
  color: var(--ink);
}

.nav-links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.nav-links a {
  border-radius: 8px;
  color: var(--ink-soft);
  font-size: 0.95rem;
  font-weight: 650;
  padding: 10px 12px;
  transition:
    background 180ms ease,
    color 180ms ease;
}

.nav-links a:hover,
.nav-links a:focus-visible,
.nav-links a.is-active {
  background: var(--bg-soft);
  color: var(--ink);
  outline: none;
}

.language-switch {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  padding: 4px;
}

.language-button,
.text-button,
.outline-button,
.icon-button {
  border: 0;
  cursor: pointer;
}

.language-button {
  min-width: 42px;
  border-radius: 6px;
  background: transparent;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 760;
  padding: 7px 8px;
}

.language-button.is-active {
  background: var(--ink);
  color: #ffffff;
}

.language-offer {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 60;
  width: min(360px, calc(100vw - 32px));
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px 12px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: var(--shadow);
  padding: 16px;
}

.language-offer[hidden] {
  display: none;
}

.language-offer p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.95rem;
}

.text-button {
  justify-self: start;
  border-radius: 8px;
  background: var(--accent);
  color: #ffffff;
  font-weight: 740;
  padding: 8px 12px;
}

.outline-button {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  color: var(--ink);
  font-weight: 740;
  padding: 8px 12px;
}

.analytics-consent {
  position: fixed;
  left: 24px;
  bottom: 24px;
  z-index: 61;
  width: min(470px, calc(100vw - 32px));
  display: grid;
  gap: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.97);
  box-shadow: var(--shadow);
  padding: 18px;
}

.analytics-consent[hidden] {
  display: none;
}

.analytics-consent p {
  margin: 0;
  color: var(--ink-soft);
}

.analytics-consent .consent-title {
  margin-bottom: 4px;
  color: var(--ink);
  font-weight: 820;
}

.consent-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.icon-button {
  grid-column: 2;
  grid-row: 1;
  width: 34px;
  height: 34px;
  border-radius: 8px;
  background: var(--bg-soft);
  color: var(--ink);
  font-size: 1.4rem;
  line-height: 1;
}

.hero {
  position: relative;
  min-height: calc(100svh - 138px);
  isolation: isolate;
  overflow: hidden;
  background: var(--ink);
}

.hero-image,
.hero-overlay {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.hero-image {
  object-fit: cover;
  transform: translate3d(0, var(--hero-offset, 0px), 0) scale(1.04);
  will-change: transform;
}

.hero-overlay {
  z-index: 1;
  background:
    linear-gradient(90deg, rgba(10, 15, 25, 0.83) 0%, rgba(10, 15, 25, 0.62) 46%, rgba(10, 15, 25, 0.22) 100%),
    linear-gradient(0deg, rgba(10, 15, 25, 0.44), rgba(10, 15, 25, 0.16));
}

.hero-content {
  position: relative;
  z-index: 2;
  width: min(100% - 40px, var(--max));
  min-height: calc(100svh - 138px);
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 72px 0 56px;
  color: #ffffff;
}

.eyebrow,
.section-kicker,
.work-type {
  margin: 0 0 12px;
  color: var(--accent);
  font-size: 0.79rem;
  font-weight: 820;
  letter-spacing: 0;
  text-transform: uppercase;
}

.hero .eyebrow {
  color: #6ee7d8;
}

h1,
h2,
h3,
p {
  overflow-wrap: anywhere;
}

h1,
h2,
h3 {
  margin-top: 0;
  line-height: 1.08;
  letter-spacing: 0;
}

h1 {
  width: min(850px, 100%);
  margin-bottom: 22px;
  font-size: 4.35rem;
}

h2 {
  margin-bottom: 18px;
  font-size: 2.75rem;
}

h3 {
  margin-bottom: 12px;
  font-size: 1.25rem;
}

.hero-lead {
  width: min(680px, 100%);
  margin: 0;
  color: rgba(255, 255, 255, 0.86);
  font-size: 1.18rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 34px;
}

.button {
  display: inline-flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  border: 1px solid transparent;
  border-radius: 8px;
  font-weight: 780;
  padding: 12px 18px;
  transition:
    transform 180ms ease,
    border-color 180ms ease,
    background 180ms ease;
}

.button:hover,
.button:focus-visible {
  transform: translateY(-2px);
  outline: none;
}

.button-primary {
  background: #ffffff;
  color: var(--ink);
}

.button-secondary {
  border-color: rgba(255, 255, 255, 0.34);
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
}

.hero-metrics {
  width: min(820px, 100%);
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  margin: 52px 0 0;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.18);
}

.hero-metrics div {
  background: rgba(255, 255, 255, 0.1);
  padding: 18px;
}

.hero-metrics dt {
  color: #ffffff;
  font-size: 1.12rem;
  font-weight: 820;
}

.hero-metrics dd {
  margin: 4px 0 0;
  color: rgba(255, 255, 255, 0.76);
  font-size: 0.92rem;
}

.section {
  padding: 96px 0;
}

.section-grid,
.section-heading,
.service-grid,
.process-section,
.work-grid,
.stack-layout,
.contact-section,
.legal-grid,
.site-footer {
  width: min(100% - 40px, var(--max));
  margin: 0 auto;
}

.section-grid,
.process-section,
.stack-layout,
.contact-section {
  display: grid;
  grid-template-columns: minmax(0, 0.92fr) minmax(0, 1.08fr);
  gap: 58px;
  align-items: center;
}

.intro-section {
  background: var(--bg);
}

.intro-text {
  display: grid;
  gap: 18px;
}

.intro-text p,
.section-copy p,
.process-content p,
.stack-feature p,
.contact-copy p,
.service-card p,
.work-copy p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 1.03rem;
}

.section-heading {
  max-width: var(--max);
  margin-bottom: 38px;
}

.section-heading h2 {
  width: min(760px, 100%);
}

.services-section,
.stack-section,
.legal-section {
  background: var(--bg-soft);
}

.service-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

.service-card,
.work-card,
.stack-feature,
.contact-link,
.project-guide {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}

.service-card,
.work-card,
.stack-feature,
.contact-link {
  position: relative;
  overflow: hidden;
}

.service-card::before,
.work-card::before,
.stack-feature::before,
.contact-link::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background: radial-gradient(
    circle at var(--mouse-x, 50%) var(--mouse-y, 50%),
    rgba(15, 118, 110, 0.12),
    transparent 34%
  );
  opacity: 0;
  transition: opacity 180ms ease;
  pointer-events: none;
}

.service-card:hover::before,
.work-card:hover::before,
.stack-feature:hover::before,
.contact-link:hover::before {
  opacity: 1;
}

.service-card > *,
.work-card > *,
.stack-feature > *,
.contact-link > * {
  position: relative;
  z-index: 1;
}

.service-card {
  min-height: 300px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 24px;
}

.service-index {
  color: var(--accent-cool);
  font-weight: 820;
}

.service-card h3 {
  margin-top: auto;
}

.process-section {
  align-items: stretch;
}

.process-visual {
  min-height: 560px;
  overflow: hidden;
  border-radius: 8px;
  background: var(--bg-muted);
}

.process-visual img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.process-content {
  align-self: center;
}

.process-list {
  display: grid;
  gap: 14px;
  margin-top: 32px;
}

.process-item {
  display: grid;
  grid-template-columns: 48px 1fr;
  gap: 18px;
  border-top: 1px solid var(--line);
  padding-top: 20px;
}

.process-item span {
  color: var(--accent-hot);
  font-weight: 820;
}

.process-item h3 {
  margin-bottom: 8px;
}

.work-section {
  background: var(--bg);
}

.work-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.work-card {
  overflow: hidden;
}

.work-card-featured {
  grid-row: span 2;
}

.work-image {
  aspect-ratio: 16 / 10;
  background: var(--bg-muted);
}

.work-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.work-copy {
  padding: 26px;
}

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 22px;
}

.tag-list span,
.stack-list li {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--bg-soft);
  color: var(--ink-soft);
  font-size: 0.92rem;
  font-weight: 720;
  padding: 8px 10px;
}

.stack-layout {
  align-items: start;
}

.stack-feature {
  padding: 30px;
  box-shadow: var(--shadow);
}

.stack-feature h3 {
  font-size: 1.55rem;
}

.stack-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-content: start;
  margin: 0;
  padding: 0;
  list-style: none;
}

.contact-section {
  align-items: start;
}

.contact-copy h2 {
  width: min(680px, 100%);
}

.contact-actions {
  display: grid;
  gap: 12px;
}

.contact-link {
  display: grid;
  gap: 4px;
  padding: 20px;
  transition:
    transform 180ms ease,
    border-color 180ms ease,
    box-shadow 180ms ease;
}

.contact-link:hover,
.contact-link:focus-visible {
  transform: translateY(-2px);
  border-color: rgba(15, 118, 110, 0.45);
  box-shadow: 0 16px 36px rgba(15, 23, 42, 0.08);
  outline: none;
}

.contact-email-row {
  grid-template-columns: 1fr auto;
  align-items: center;
}

.contact-email-row a {
  display: grid;
  gap: 4px;
}

.copy-button {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--bg-soft);
  color: var(--ink);
  cursor: pointer;
  font-weight: 760;
  padding: 9px 12px;
  transition:
    background 180ms ease,
    border-color 180ms ease;
}

.copy-button:hover,
.copy-button:focus-visible {
  border-color: rgba(15, 118, 110, 0.45);
  background: #ffffff;
  outline: none;
}

.contact-link span {
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 720;
}

.contact-link strong {
  color: var(--ink);
  font-size: 1.08rem;
  overflow-wrap: anywhere;
}

.legal-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.legal-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  padding: 26px;
}

.legal-card p {
  margin: 0 0 14px;
  color: var(--ink-soft);
}

.legal-card p:last-child {
  margin-bottom: 0;
}

.legal-card dl {
  display: grid;
  gap: 16px;
  margin: 0;
}

.legal-card dt {
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 760;
}

.legal-card dd {
  margin: 4px 0 0;
  color: var(--ink);
  font-weight: 720;
  overflow-wrap: anywhere;
}

.project-guide {
  grid-column: 1 / -1;
  display: grid;
  gap: 16px;
  margin-top: 8px;
  padding: 26px;
  box-shadow: var(--shadow);
}

.project-guide h3 {
  margin-bottom: 0;
  font-size: 1.55rem;
}

.project-guide p {
  margin: 0;
  color: var(--ink-soft);
}

.guide-options {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.guide-options button {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--bg-soft);
  color: var(--ink-soft);
  cursor: pointer;
  font-weight: 760;
  padding: 10px 12px;
  transition:
    background 180ms ease,
    border-color 180ms ease,
    color 180ms ease,
    transform 180ms ease;
}

.guide-options button:hover,
.guide-options button:focus-visible,
.guide-options button.is-selected {
  border-color: rgba(15, 118, 110, 0.5);
  background: rgba(15, 118, 110, 0.09);
  color: var(--accent-strong);
  outline: none;
  transform: translateY(-1px);
}

.guide-result {
  min-height: 72px;
  border-left: 3px solid var(--accent);
  background: var(--bg-soft);
  color: var(--ink-soft);
  padding: 14px 16px;
}

.guide-mail-button {
  width: fit-content;
  background: var(--ink);
  color: #ffffff;
}

.floating-top {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 55;
  width: 46px;
  height: 46px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: var(--shadow);
  color: var(--ink);
  cursor: pointer;
  font-size: 1.2rem;
  font-weight: 820;
  opacity: 0;
  pointer-events: none;
  transform: translateY(12px);
  transition:
    opacity 180ms ease,
    transform 180ms ease;
}

.floating-top.is-visible {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.reveal-item {
  opacity: 0;
  transform: translateY(22px);
  transition:
    opacity 520ms ease,
    transform 520ms ease;
}

.reveal-item.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  padding: 28px 0 42px;
}

.site-footer p {
  margin: 0;
}

.site-footer a {
  color: var(--ink);
  font-weight: 760;
}

.not-found-page {
  min-height: 100svh;
  background:
    linear-gradient(120deg, rgba(15, 118, 110, 0.08), transparent 36%),
    linear-gradient(300deg, rgba(3, 105, 161, 0.08), transparent 32%),
    var(--bg-soft);
}

.not-found {
  width: min(100% - 40px, 940px);
  min-height: 100svh;
  display: grid;
  align-content: center;
  gap: 28px;
  margin: 0 auto;
  padding: 48px 0;
}

.not-found-brand {
  width: fit-content;
}

.not-found-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: var(--shadow);
  padding: clamp(28px, 7vw, 62px);
}

.not-found-panel h1 {
  width: min(720px, 100%);
  font-size: clamp(2.4rem, 7vw, 5rem);
}

.not-found-panel p {
  width: min(650px, 100%);
  margin: 0 0 16px;
  color: var(--ink-soft);
  font-size: 1.08rem;
}

.not-found-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 30px;
}

.not-found-primary {
  background: var(--ink);
  color: #ffffff;
}

.not-found-secondary {
  border-color: var(--line);
  background: #ffffff;
  color: var(--ink);
}

@media (max-width: 1060px) {
  .nav-links {
    display: none;
  }

  h1 {
    font-size: 3.45rem;
  }

  h2 {
    font-size: 2.25rem;
  }

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

  .section-grid,
  .process-section,
  .stack-layout,
  .contact-section {
    grid-template-columns: 1fr;
  }

  .process-visual {
    min-height: 420px;
  }
}

@media (max-width: 760px) {
  :root {
    --header: 68px;
  }

  .nav-shell,
  .section-grid,
  .section-heading,
  .service-grid,
  .process-section,
  .work-grid,
  .stack-layout,
  .contact-section,
  .site-footer,
  .hero-content {
    width: min(100% - 28px, var(--max));
  }

  .brand-text {
    display: none;
  }

  .language-button {
    min-width: 38px;
  }

  .hero,
  .hero-content {
    min-height: calc(100svh - 118px);
  }

  .hero-content {
    padding: 54px 0 34px;
  }

  h1 {
    font-size: 2.35rem;
  }

  h2 {
    font-size: 1.9rem;
  }

  .hero-lead {
    font-size: 1rem;
  }

  .hero-actions {
    display: grid;
  }

  .button {
    width: 100%;
  }

  .hero-metrics,
  .service-grid,
  .work-grid,
  .legal-grid {
    grid-template-columns: 1fr;
  }

  .hero-metrics {
    margin-top: 34px;
  }

  .section {
    padding: 68px 0;
  }

  .service-card {
    min-height: 240px;
  }

  .process-visual {
    min-height: 300px;
  }

  .process-item {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .site-footer {
    flex-direction: column;
  }

  .not-found-actions {
    display: grid;
  }

  .contact-email-row {
    grid-template-columns: 1fr;
  }

  .copy-button,
  .guide-mail-button {
    width: 100%;
  }

  .floating-top {
    right: 14px;
    bottom: 14px;
  }
}

@media (max-width: 420px) {
  .nav-shell {
    gap: 10px;
  }

  .brand-mark {
    width: 38px;
    height: 38px;
  }

  h1 {
    font-size: 2rem;
  }

  h2 {
    font-size: 1.65rem;
  }

  .language-offer {
    right: 14px;
    bottom: 14px;
    width: calc(100vw - 28px);
  }

  .analytics-consent {
    left: 14px;
    bottom: 14px;
    width: calc(100vw - 28px);
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }

  .hero-image {
    transform: none;
  }

  .reveal-item {
    opacity: 1;
    transform: none;
  }
}
