/* ============================================================
   Gaido R&D — light, minimal single page
   ============================================================ */

:root {
  --brand: #2c33f7;
  --brand-dark: #1d23c9;

  --bg: #ffffff;
  --bg-soft: #f5f6f9;
  --text: #0f1118;
  --muted: #5c6172;
  --border: #e6e7ee;

  --container: 1080px;
  --radius: 14px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Inter", system-ui, -apple-system, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

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

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

ul {
  list-style: none;
}

h1,
h2,
h3 {
  font-family: "Space Grotesk", "Inter", sans-serif;
  line-height: 1.08;
  font-weight: 600;
  letter-spacing: -0.02em;
}

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

.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: clamp(1.2rem, 5vw, 2.2rem);
}

.skip-link {
  position: fixed;
  top: -100px;
  left: 1rem;
  z-index: 200;
  background: var(--brand);
  color: #fff;
  padding: 0.6rem 1rem;
  border-radius: 10px;
  transition: top 0.2s;
}
.skip-link:focus {
  top: 1rem;
}

/* ---------- Decorative background ---------- */
.bg-decor {
  position: fixed;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  background: var(--bg);
}
/* subtle dot grid, fading downward */
.bg-decor::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(15, 17, 24, 0.05) 1px, transparent 1.5px);
  background-size: 26px 26px;
  -webkit-mask-image: radial-gradient(120% 80% at 50% -10%, #000 28%, transparent 80%);
  mask-image: radial-gradient(120% 80% at 50% -10%, #000 28%, transparent 80%);
}
/* soft brand-tinted light washes */
.aurora {
  position: absolute;
  border-radius: 50%;
  filter: blur(90px);
  will-change: transform;
}
.aurora--1 {
  width: 620px;
  height: 620px;
  background: radial-gradient(circle, rgba(44, 51, 247, 0.16), transparent 70%);
  top: -240px;
  right: -120px;
  animation: drift1 26s var(--ease) infinite;
}
.aurora--2 {
  width: 480px;
  height: 480px;
  background: radial-gradient(circle, rgba(44, 51, 247, 0.1), transparent 70%);
  bottom: -200px;
  left: -140px;
  animation: drift2 30s var(--ease) infinite;
}
/* faint film grain for a tactile, non-flat surface */
.grain {
  position: absolute;
  inset: 0;
  opacity: 0.04;
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
@keyframes drift1 {
  50% { transform: translate(-50px, 40px) scale(1.12); }
}
@keyframes drift2 {
  50% { transform: translate(50px, -36px) scale(1.14); }
}

/* ---------- Header ---------- */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  padding-block: 1.25rem;
  background: rgba(255, 255, 255, 0);
  border-bottom: 1px solid transparent;
  transition: padding 0.3s var(--ease), background 0.3s, border-color 0.3s;
}
.site-header.scrolled {
  padding-block: 0.8rem;
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom-color: var(--border);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.brand__logo {
  height: 34px;
  width: auto;
  transition: opacity 0.2s;
}
.brand:hover .brand__logo {
  opacity: 0.78;
}

.nav__links {
  display: flex;
  align-items: center;
  gap: 1.6rem;
}
.nav__links > a:not(.btn) {
  font-size: 0.96rem;
  color: var(--muted);
  transition: color 0.2s;
}
.nav__links > a:not(.btn):hover {
  color: var(--text);
}

.nav__toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 42px;
  height: 42px;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 11px;
  cursor: pointer;
}
.nav__toggle span {
  display: block;
  width: 19px;
  height: 2px;
  margin-inline: auto;
  background: var(--text);
  border-radius: 2px;
  transition: transform 0.3s var(--ease), opacity 0.2s;
}
.nav__toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.nav__toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}
.nav__toggle[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* header contact button — desktop uses the nav button, so hide by default */
.header-cta {
  display: none;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.8rem 1.5rem;
  font-family: "Inter", sans-serif;
  font-weight: 500;
  font-size: 0.98rem;
  border-radius: 999px;
  border: 1px solid transparent;
  cursor: pointer;
  white-space: nowrap;
  transition: transform 0.2s var(--ease), background 0.2s, border-color 0.2s, color 0.2s;
}
.btn--sm { padding: 0.5rem 1.1rem; font-size: 0.92rem; }
.btn--lg { padding: 0.95rem 1.9rem; font-size: 1.02rem; }

.btn--primary {
  background: var(--brand);
  color: #fff;
}
.btn--primary:hover {
  background: var(--brand-dark);
  transform: translateY(-1px);
}

/* ---------- Sections ---------- */
.section {
  padding-block: clamp(4.5rem, 11vw, 8.5rem);
}
[id] { scroll-margin-top: 90px; }

.section-head {
  margin-bottom: clamp(2.5rem, 6vw, 4rem);
}
.overline {
  font-size: 0.82rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--brand);
  margin-bottom: 0.9rem;
}
.section-title {
  font-size: clamp(1.8rem, 4.5vw, 2.8rem);
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 88svh;
  display: flex;
  align-items: center;
  padding-top: 6rem;
  overflow: hidden;
}
.hero .container {
  position: relative;
  z-index: 1;
}
.hero__inner {
  max-width: 760px;
}
.hero__title {
  font-size: clamp(2.6rem, 8vw, 5.2rem);
  font-weight: 700;
  letter-spacing: -0.035em;
}
.hero__lead {
  margin-top: 1.6rem;
  font-size: clamp(1.05rem, 2.2vw, 1.35rem);
  color: var(--muted);
  max-width: 54ch;
}
.hero__actions {
  margin-top: 2.4rem;
}

/* hero brand motif */
.hero__mark {
  position: absolute;
  right: -2%;
  top: 50%;
  translate: 0 -50%;
  width: clamp(220px, 32vw, 440px);
  opacity: 0.1;
  z-index: 0;
  pointer-events: none;
  animation: floatMark 16s var(--ease) infinite;
}
@keyframes floatMark {
  50% { transform: translateY(-20px) rotate(-4deg); }
}

/* staggered hero entrance */
.hero__inner .reveal:nth-child(1) { transition-delay: 0.05s; }
.hero__inner .reveal:nth-child(2) { transition-delay: 0.16s; }
.hero__inner .reveal:nth-child(3) { transition-delay: 0.27s; }

/* button arrow micro-interaction */
.btn svg { transition: transform 0.2s var(--ease); }
.btn--primary:hover svg { transform: translateX(3px); }

/* ---------- References & Partners ---------- */
.references,
.partners {
  border-top: 1px solid var(--border);
}
.logos,
.partners-grid {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-evenly;
  gap: 1.5rem 2rem;
}
/* logos shown directly — no card, no border, no crop */
.logos .logo img {
  height: clamp(54px, 6.5vw, 80px);
  width: auto;
  max-width: 100%;
  object-fit: contain;
}
.partners-grid .logo img {
  height: clamp(44px, 5vw, 60px);
  width: auto;
  max-width: 100%;
  object-fit: contain;
}

/* ---------- Footer ---------- */
.site-footer {
  border-top: 1px solid var(--border);
  padding-top: clamp(2.5rem, 6vw, 3.5rem);
  padding-bottom: 2rem;
}
.footer__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1.5rem;
  padding-bottom: 2.2rem;
}
.footer__logo {
  height: 30px;
  width: auto;
  margin-bottom: 0.8rem;
}
.footer__brand p {
  color: var(--muted);
  max-width: 30ch;
}
.footer__mail {
  font-family: "Space Grotesk", sans-serif;
  font-size: 1.05rem;
  color: var(--text);
  border-bottom: 1px solid var(--border);
  padding-bottom: 2px;
  transition: border-color 0.2s;
}
.footer__mail:hover {
  border-color: var(--brand);
}
.footer__bottom {
  padding-top: 1.6rem;
  border-top: 1px solid var(--border);
  color: var(--muted);
  font-size: 0.86rem;
}

/* ---------- Reveal ---------- */
.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.6s var(--ease), transform 0.6s var(--ease);
}
.reveal.is-visible {
  opacity: 1;
  transform: none;
}

/* ---------- Responsive ---------- */
@media (max-width: 760px) {
  /* short page on mobile: no hamburger, no slide-out menu */
  .nav__links { display: none; }
  .nav__toggle { display: none; }

  /* contact button fades into the header once the hero CTA scrolls away */
  .header-cta {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.5rem 1.1rem;
    font-family: "Inter", sans-serif;
    font-weight: 500;
    font-size: 0.92rem;
    color: #fff;
    background: var(--brand);
    border-radius: 999px;
    opacity: 0;
    transform: translateY(-6px);
    pointer-events: none;
    transition: opacity 0.3s var(--ease), transform 0.3s var(--ease);
  }
  body.past-hero .header-cta {
    opacity: 1;
    transform: none;
    pointer-events: auto;
  }

  .hero__mark { opacity: 0.06; width: 240px; right: -70px; }
}

@media (max-width: 460px) {
  .hero__actions .btn { width: 100%; }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    transition-duration: 0.01ms !important;
  }
  .reveal { opacity: 1; transform: none; }
}
