/* =====================================================================
   IntelliLabs AI — design system (shared by every page)
   Layout idea: a deep-navy stage where ideas take shape, then a bright,
   left-aligned workbench of content. The logo's coloured pipes ( | ) and
   the brand's arrow formulas (THINK → CODE → CREATE) are the two
   recurring devices.
   ===================================================================== */

:root {
  color-scheme: light;

  /* Colour — sampled from the approved logo */
  --navy-950: #040b2a;   /* hero, enquiry band */
  --navy-900: #081238;   /* raised surfaces on navy */
  --navy-800: #0f1c55;
  --navy-footer: #030820;
  --ink: #0b1340;        /* text on light */
  --ink-soft: #44507c;   /* secondary text on light */
  --paper: #ffffff;
  --mist: #f2f5fd;       /* tinted section ground */
  --line: #d9e0f3;
  --blue: #1f5bff;       /* electric blue: primary accent, actions */
  --blue-deep: #1447d9;
  --blue-soft: #e6edff;
  --cyan: #21c7f3;
  --cyan-deep: #0a7fa6;
  --magenta: #f03ccb;
  --magenta-deep: #b01a93;
  --purple: #7a3cf0;
  --purple-deep: #5b25c9;
  --note: #ffe27a;       /* the yellow brush label from the brand posters */
  --on-dark: #f4f7ff;
  --on-dark-soft: #b7c1e6;
  --on-dark-line: rgba(183, 193, 230, 0.2);
  --ok: #0a7a4b;
  --error: #b3261e;

  /* Type */
  --font-display: "Lexend", "Avenir Next", "Segoe UI", system-ui, sans-serif;
  --font-body: "Figtree", "Segoe UI", system-ui, -apple-system, sans-serif;
  --font-hand: "Kalam", "Segoe Print", "Bradley Hand", cursive;

  --fs-h1: clamp(2rem, 0.95rem + 4.3vw, 3.9rem);
  --fs-h2: clamp(1.8rem, 1.25rem + 2.2vw, 2.8rem);
  --fs-h3: clamp(1.2rem, 1.08rem + 0.5vw, 1.45rem);
  --fs-lead: clamp(1.06rem, 1rem + 0.35vw, 1.25rem);
  --fs-body: 1.0625rem;
  --fs-small: 0.9375rem;
  --fs-label: 0.8125rem;

  /* Space and shape */
  --gutter: clamp(16px, 4vw, 40px);
  --wrap: 1200px;
  --section: clamp(64px, 9vw, 128px);
  --r-sm: 10px;
  --r-md: 18px;
  --r-lg: 28px;
  --shadow-card: 0 1px 2px rgba(11, 19, 64, 0.06), 0 12px 32px -12px rgba(11, 19, 64, 0.18);
  --shadow-lift: 0 2px 4px rgba(11, 19, 64, 0.08), 0 24px 48px -16px rgba(31, 91, 255, 0.28);
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
  --header-h: 86px;
}

/* ---------- Base ---------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: var(--fs-body);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg { display: block; max-width: 100%; }
img { height: auto; }
h1, h2, h3, h4 { font-family: var(--font-display); line-height: 1.12; margin: 0; text-wrap: balance; letter-spacing: -0.015em; }
p { margin: 0; text-wrap: pretty; }
ul, ol { margin: 0; padding: 0; list-style: none; }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 3px solid var(--cyan); outline-offset: 3px; border-radius: 6px; }
::selection { background: var(--blue); color: #fff; }

.wrap { width: 100%; max-width: calc(var(--wrap) + var(--gutter) * 2); margin-inline: auto; padding-inline: var(--gutter); }
.section { padding-block: var(--section); }
.section--mist { background: var(--mist); }
.section--navy { background: var(--navy-950); color: var(--on-dark); }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip-link { position: absolute; left: 16px; top: -80px; z-index: 200; background: var(--paper); color: var(--ink); padding: 10px 16px; border-radius: var(--r-sm); font-weight: 600; }
.skip-link:focus { top: 12px; }

/* ---------- Brand devices ------------------------------------------- */
/* The two coloured pipes from "IMAGINE | BUILD | INNOVATE" */
.eyebrow {
  display: inline-flex; align-items: center; gap: 12px;
  font-family: var(--font-display); font-size: var(--fs-label); font-weight: 600;
  letter-spacing: 0.16em; text-transform: uppercase; color: var(--ink-soft);
}
.eyebrow::before {
  content: ""; flex: none; width: 9px; height: 16px;
  background: linear-gradient(90deg, var(--cyan) 0 3px, transparent 3px 6px, var(--magenta) 6px 9px);
}
.section--navy .eyebrow, .hero .eyebrow { color: var(--on-dark-soft); }

.section-head { display: grid; gap: 18px; max-width: 760px; margin-bottom: clamp(32px, 5vw, 56px); }
.section-head h2 { font-size: var(--fs-h2); font-weight: 700; }
.section-head > p:not(.eyebrow) { font-size: var(--fs-lead); color: var(--ink-soft); max-width: 62ch; }
.section--navy .section-head > p:not(.eyebrow) { color: var(--on-dark-soft); }

/* Arrow formulas: THINK → CODE → CREATE */
.formula {
  display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px;
  font-family: var(--font-display); font-size: var(--fs-label); font-weight: 700;
  letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink);
}
.formula span, .nowrap { white-space: nowrap; }
.formula i { font-style: normal; display: inline-block; color: var(--accent, var(--blue)); transition: transform 0.4s var(--ease); }

/* Handwritten notes, used sparingly */
.hand { font-family: var(--font-hand); font-weight: 700; letter-spacing: 0; }

/* ---------- Buttons ------------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 50px; padding: 12px 26px; border-radius: 999px; border: 2px solid transparent;
  font-family: var(--font-display); font-size: 0.975rem; font-weight: 600; letter-spacing: 0.01em;
  text-decoration: none; text-align: center; line-height: 1.2;
  transition: background-color 0.2s, color 0.2s, border-color 0.2s, transform 0.2s var(--ease), box-shadow 0.2s;
}
.btn svg { flex: none; width: 18px; height: 18px; }
.btn:active { transform: translateY(1px); }
.btn--primary { background: var(--blue); color: #fff; box-shadow: 0 10px 24px -10px rgba(31, 91, 255, 0.7); }
.btn--primary:hover { background: var(--blue-deep); }
.btn--ghost { border-color: rgba(244, 247, 255, 0.34); color: var(--on-dark); }
.btn--ghost:hover { border-color: var(--on-dark); background: rgba(244, 247, 255, 0.08); }
.btn--outline { border-color: var(--line); color: var(--ink); background: var(--paper); }
.btn--outline:hover { border-color: var(--blue); color: var(--blue-deep); }
.btn--whatsapp { background: #0f7a40; color: #fff; }
.btn--whatsapp:hover { background: #0c6936; }
.btn--small { min-height: 42px; padding: 8px 20px; font-size: 0.9rem; }

.link-arrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--font-display); font-weight: 600; font-size: 0.975rem;
  color: var(--blue-deep); text-decoration: none; padding-block: 6px;
}
.link-arrow svg { width: 18px; height: 18px; transition: transform 0.25s var(--ease); }
.link-arrow:hover svg { transform: translateX(4px); }
.link-arrow:hover { text-decoration: underline; text-underline-offset: 4px; }
.section--navy .link-arrow, .hero .link-arrow { color: var(--on-dark); }

/* ---------- Status chips -------------------------------------------- */
.chip {
  display: inline-flex; align-items: center; gap: 8px; padding: 5px 12px 5px 10px; border-radius: 999px;
  font-family: var(--font-display); font-size: 0.75rem; font-weight: 600; letter-spacing: 0.04em; white-space: nowrap;
}
.chip::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: currentColor; }
.chip--open { background: #e2f6ec; color: var(--ok); }
.chip--interest { background: #f1eafe; color: var(--purple-deep); }
.chip--interest::before { background: transparent; box-shadow: inset 0 0 0 2px currentColor; }

/* ---------- Header --------------------------------------------------- */
.site-header {
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 100;
  background: var(--navy-950); color: var(--on-dark);
  border-bottom: 1px solid var(--on-dark-line);
}
.site-header__bar { display: flex; align-items: center; gap: 24px; min-height: var(--header-h); }
.brand { display: inline-flex; flex: none; text-decoration: none; margin-left: -6px; }
.brand img { height: 72px; width: auto; }
.nav { margin-left: auto; }
.nav__list { display: flex; align-items: center; gap: 4px; }
.nav__link, .nav__toggle {
  display: inline-flex; align-items: center; gap: 6px; padding: 10px 14px; border: 0; background: none; border-radius: 999px;
  font-family: var(--font-display); font-size: 0.925rem; font-weight: 500; color: var(--on-dark); text-decoration: none; white-space: nowrap;
  transition: background-color 0.2s, color 0.2s;
}
.nav__link:hover, .nav__toggle:hover, .nav__toggle[aria-expanded="true"] { background: rgba(244, 247, 255, 0.1); }
.nav__link[aria-current="page"] { color: var(--cyan); }
.nav__toggle svg { width: 14px; height: 14px; transition: transform 0.2s; }
.nav__toggle[aria-expanded="true"] svg { transform: rotate(180deg); }
.nav__item { position: relative; }
.nav__menu {
  position: absolute; top: calc(100% + 12px); left: 0; min-width: 320px; padding: 10px;
  background: var(--navy-900); border: 1px solid var(--on-dark-line); border-radius: var(--r-md);
  box-shadow: 0 24px 48px -12px rgba(0, 0, 0, 0.6);
}
.nav__menu a { display: grid; gap: 2px; padding: 12px 14px; border-radius: 12px; text-decoration: none; }
.nav__menu a:hover { background: rgba(244, 247, 255, 0.08); }
.nav__menu strong { font-family: var(--font-display); font-size: 0.95rem; font-weight: 600; }
.nav__menu span { font-size: 0.8rem; color: var(--on-dark-soft); letter-spacing: 0.04em; }
.site-header__cta { flex: none; }
.nav-open { display: none; width: 46px; height: 46px; border: 1px solid var(--on-dark-line); border-radius: 12px; background: none; color: var(--on-dark); align-items: center; justify-content: center; }
.nav-open svg { width: 22px; height: 22px; }
.nav-open .icon-close, .nav-open[aria-expanded="true"] .icon-menu { display: none; }
.nav-open[aria-expanded="true"] .icon-close { display: block; }

@media (max-width: 1040px) {
  :root { --header-h: 64px; }
  .brand img { height: 54px; }
  .nav-open { display: inline-flex; margin-left: auto; }
  .site-header__cta { display: none; }
  .nav {
    position: absolute; left: 0; right: 0; top: 100%; margin: 0;
    background: var(--navy-950); border-bottom: 1px solid var(--on-dark-line);
    max-height: calc(100vh - var(--header-h)); overflow-y: auto; padding: 8px var(--gutter) 28px;
  }
  .nav:not(.is-open) { display: none; }
  .nav__list { flex-direction: column; align-items: stretch; gap: 0; }
  .nav__item { border-bottom: 1px solid var(--on-dark-line); }
  .nav__link, .nav__toggle { width: 100%; justify-content: space-between; padding: 16px 4px; font-size: 1.05rem; border-radius: 8px; }
  .nav__toggle { pointer-events: none; color: var(--on-dark-soft); font-size: var(--fs-label); letter-spacing: 0.16em; text-transform: uppercase; padding-bottom: 4px; }
  .nav__toggle svg { display: none; }
  .nav__menu { position: static; min-width: 0; padding: 0 0 10px; background: none; border: 0; box-shadow: none; }
  .nav__menu[hidden] { display: block !important; }
  .nav__menu a { padding: 10px 4px; }
  .nav__cta-mobile { display: flex; margin-top: 20px; }
}
@media (min-width: 1041px) { .nav__cta-mobile { display: none; } }

/* ---------- Footer --------------------------------------------------- */
.site-footer { background: var(--navy-footer); color: var(--on-dark-soft); font-size: var(--fs-small); padding-block: clamp(48px, 7vw, 80px) 28px; }
.site-footer__grid { display: grid; gap: 40px clamp(24px, 3vw, 48px); grid-template-columns: minmax(0, 1.5fr) repeat(2, minmax(0, 0.9fr)) minmax(0, 1.15fr) minmax(0, 0.8fr); }
.site-footer__brand img { height: 84px; width: auto; margin: -10px 0 6px -10px; }
.site-footer__brand p { max-width: 40ch; }
.site-footer__brand .hand { display: block; margin-top: 16px; color: var(--on-dark); font-size: 1.15rem; line-height: 1.35; }
.site-footer h2 { font-size: var(--fs-label); font-weight: 600; letter-spacing: 0.16em; text-transform: uppercase; color: var(--on-dark); margin-bottom: 16px; }
.site-footer li + li { margin-top: 10px; }
.site-footer a { text-decoration: none; }
.site-footer a:hover { color: var(--on-dark); text-decoration: underline; text-underline-offset: 4px; }
.site-footer__contact li { overflow-wrap: anywhere; }
.site-footer__contact small { display: block; font-size: 0.75rem; letter-spacing: 0.08em; text-transform: uppercase; color: #8f9bc8; }
.site-footer__social a { display: inline-flex; align-items: center; gap: 10px; }
.site-footer__social svg { width: 20px; height: 20px; }
.site-footer__base { display: flex; flex-wrap: wrap; gap: 8px 24px; justify-content: space-between; margin-top: 48px; padding-top: 24px; border-top: 1px solid var(--on-dark-line); font-size: 0.85rem; }
.site-footer__tagline { font-family: var(--font-display); font-weight: 600; letter-spacing: 0.2em; color: var(--on-dark); }
.site-footer__tagline i { font-style: normal; padding-inline: 8px; }
.site-footer__tagline i:first-of-type { color: var(--cyan); }
.site-footer__tagline i:last-of-type { color: var(--magenta); }
@media (max-width: 1040px) { .site-footer__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .site-footer__brand { grid-column: 1 / -1; } }
@media (max-width: 520px) { .site-footer__grid { grid-template-columns: minmax(0, 1fr); } }

/* ---------- Forms ---------------------------------------------------- */
.field { display: grid; gap: 6px; min-width: 0; }
.field label { font-family: var(--font-display); font-size: 0.875rem; font-weight: 600; color: var(--ink); }
.field label span { font-weight: 400; color: var(--ink-soft); }
.field input, .field select, .field textarea {
  width: 100%; min-height: 50px; padding: 12px 14px; border: 1.5px solid var(--line); border-radius: var(--r-sm);
  background: var(--paper); color: var(--ink); transition: border-color 0.2s, box-shadow 0.2s;
}
.field textarea { min-height: 120px; resize: vertical; }
.field input:hover, .field select:hover, .field textarea:hover { border-color: #b4c0e6; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 4px rgba(31, 91, 255, 0.16); }
.field [aria-invalid="true"] { border-color: var(--error); }
.field__error { font-size: 0.85rem; color: var(--error); font-weight: 600; }

/* ---------- Copy-to-clipboard rows ---------------------------------- */
.copy-row { display: flex; align-items: center; gap: 12px; min-width: 0; }
.copy-row__text { min-width: 0; overflow-wrap: anywhere; user-select: all; }
.copy-btn {
  flex: none; display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 999px;
  border: 1px solid var(--on-dark-line); background: none; color: var(--on-dark-soft);
  font-family: var(--font-display); font-size: 0.75rem; font-weight: 600; letter-spacing: 0.04em;
}
.copy-btn:hover { color: var(--on-dark); border-color: var(--on-dark-soft); }
.copy-btn svg { width: 14px; height: 14px; }

/* ---------- Scroll reveal (only armed after the first scroll) -------- */
[data-reveal].reveal-armed { opacity: 0; transform: translateY(22px); }
[data-reveal].reveal-in { opacity: 1; transform: none; transition: opacity 0.7s var(--ease), transform 0.7s var(--ease); transition-delay: var(--reveal-delay, 0s); }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.001s !important; animation-iteration-count: 1 !important; transition-duration: 0.001s !important; }
  [data-reveal].reveal-armed { opacity: 1; transform: none; }
}
