/* Asconix Systems — styles
   Follows the Asconix corporate identity (asconix-ci v1.0):
   - Teal #076D6D on light, Teal Light #2EC9BF on dark, Slate for secondary text, Night #0D151B as dark background.
   - Amber #E29E2C lives in the logo's top-left tile only. It is never used for text, lines or buttons.
   - Outfit for headlines (SemiBold), Inter for body text.
   - Corner radius follows the logo tile: 0.3 x the element size. */

@font-face {
  font-family: "Outfit";
  src: url("fonts/Outfit-Regular.woff") format("woff");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Outfit";
  src: url("fonts/Outfit-Medium.woff") format("woff");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Outfit";
  src: url("fonts/Outfit-SemiBold.woff") format("woff");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Inter";
  src: url("fonts/Inter-latin-variable.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

:root {
  /* CI colours */
  --teal: #076d6d;
  --teal-light: #2ec9bf;
  --slate: #58626c;
  --slate-light: #9ba7b1;
  --night: #0d151b;
  --ink: #222222;
  --white: #ffffff;

  /* Supporting neutrals derived from the CI palette */
  --tint: #f2f5f6;
  --rule: rgba(88, 98, 108, 0.32);
  --rule-dark: rgba(155, 167, 177, 0.28);

  --font-heading: "Outfit", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --radius: 0.3em;

  --gutter: clamp(1.25rem, 5vw, 3.5rem);
  --max: 76rem;
  --header-h: 5.5rem;
  --header-h-compact: 3.75rem;
}

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

html { scroll-behavior: smooth; scroll-padding-top: 4.75rem; }

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--slate);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
}

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

a { color: inherit; }

h1, h2, h3, p, ul, ol { margin: 0; }
ul, ol { padding: 0; list-style: none; }

h1, h2, h3 {
  font-family: var(--font-heading);
  font-weight: 600;
  color: var(--ink);
}

:focus-visible {
  outline: 3px solid var(--teal);
  outline-offset: 3px;
}

.hero :focus-visible,
.contact :focus-visible,
.site-footer :focus-visible {
  outline-color: var(--teal-light);
}

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

.skip {
  position: absolute;
  left: 1rem;
  top: -4rem;
  padding: 0.6rem 1rem;
  background: var(--white);
  color: var(--ink);
  border-radius: var(--radius);
  z-index: 100;
  transition: top 0.15s;
}
.skip:focus { top: 1rem; }

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--white);
  color: var(--ink);
  border-bottom: 1px solid var(--rule);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 2rem;
  min-height: var(--header-h);
  transition: min-height 0.2s ease;
}

.site-header.is-compact .header-inner { min-height: var(--header-h-compact); }

.brand {
  display: block;
  margin-right: auto;
  line-height: 0;
}

/* Brand rule: the logo with tagline is used from 280 px wide; below that the version without tagline takes over. */
.brand-full { width: 280px; height: auto; }
.brand-short { display: none; width: 170px; height: auto; }

.site-header.is-compact .brand-full { display: none; }
.site-header.is-compact .brand-short { display: block; }

.nav { display: flex; gap: 1.75rem; }
.nav a {
  text-decoration: none;
  font-weight: 500;
  font-size: 0.97rem;
  color: var(--ink);
  padding: 0.35rem 0;
  border-bottom: 2px solid transparent;
}
.nav a:hover { border-bottom-color: var(--teal); }

.lang { display: flex; border: 1px solid var(--rule); border-radius: 999px; padding: 2px; }
.lang button {
  font: inherit;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--slate);
  background: transparent;
  border: 0;
  border-radius: 999px;
  padding: 0.3rem 0.75rem;
  cursor: pointer;
}
.lang button[aria-pressed="true"] { background: var(--teal); color: var(--white); }

/* ---------- Hero ---------- */

.hero {
  position: relative;
  overflow: hidden;
  background: var(--night);
  color: var(--white);
  min-height: min(44rem, calc(100svh - var(--header-h)));
  display: flex;
  align-items: flex-end;
}

.contours {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(90deg, rgba(13, 21, 27, 0.9) 0%, rgba(13, 21, 27, 0.55) 45%, rgba(13, 21, 27, 0) 80%);
}

.hero-inner {
  position: relative;
  z-index: 2;
  padding-block: clamp(3rem, 9vw, 6.5rem);
}

.hero h1 {
  font-size: clamp(2.75rem, 7.6vw, 6.25rem);
  line-height: 1;
  letter-spacing: -0.025em;
  color: var(--white);
  max-width: 12ch;
  text-wrap: balance;
}

.hero-lead {
  margin-top: 1.75rem;
  max-width: 34rem;
  font-size: clamp(1.08rem, 1.5vw, 1.25rem);
  line-height: 1.55;
  color: var(--slate-light);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  margin-top: 2.25rem;
}

/* ---------- Buttons (used on dark backgrounds) ---------- */

.btn {
  display: inline-block;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 1rem;
  text-decoration: none;
  padding: 0.85rem 1.5rem;
  border-radius: var(--radius);
  border: 2px solid transparent;
  cursor: pointer;
  transition: background-color 0.15s, border-color 0.15s, color 0.15s;
}
.btn-primary { background: var(--teal-light); color: var(--night); }
.btn-primary:hover { background: var(--white); }
.btn-ghost { border-color: var(--slate-light); color: var(--white); }
.btn-ghost:hover { background: rgba(155, 167, 177, 0.16); }

/* ---------- Sections ---------- */

.section { padding-block: clamp(4rem, 9vw, 7.5rem); }
.section-tint { background: var(--tint); }

.section-head {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  gap: 1.5rem 4rem;
  align-items: end;
  margin-bottom: clamp(2.5rem, 5vw, 4rem);
}

h2 {
  font-size: clamp(2rem, 4.4vw, 3.2rem);
  line-height: 1.08;
  letter-spacing: -0.02em;
  color: var(--teal);
  text-wrap: balance;
}

.lead {
  font-size: 1.18rem;
  line-height: 1.6;
  color: var(--slate);
  max-width: 36rem;
}

/* ---------- Services ---------- */

.service {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  gap: 1.5rem 4rem;
  padding-block: 2.5rem;
  border-top: 1px solid var(--ink);
}
.service:last-child { border-bottom: 1px solid var(--ink); }

.service h3 {
  font-size: clamp(1.65rem, 3vw, 2.25rem);
  line-height: 1.12;
  letter-spacing: -0.015em;
}

.service-body p { max-width: 36rem; }

.service-body ul { margin-top: 1.5rem; max-width: 36rem; }
.service-body li {
  padding: 0.6rem 0;
  border-top: 1px solid var(--rule);
  font-weight: 500;
  color: var(--ink);
}
.service-body li:last-child { border-bottom: 1px solid var(--rule); }

/* ---------- Products (Kvile) ---------- */

.products {
  background: var(--night);
  color: var(--white);
}
.products h2,
.products h3 { color: var(--white); }
.products .lead { color: var(--slate-light); }
.products :focus-visible { outline-color: var(--teal-light); }

.product {
  display: grid;
  grid-template-columns: minmax(0, 4fr) minmax(0, 7fr);
  gap: 2.5rem 4rem;
  align-items: start;
  padding-top: 2.5rem;
  border-top: 1px solid var(--rule-dark);
}

.product-copy h3 {
  font-size: clamp(2.4rem, 4.6vw, 3.4rem);
  line-height: 1;
  letter-spacing: -0.02em;
}

.product-tag {
  margin-top: 0.75rem;
  font-family: var(--font-heading);
  font-weight: 500;
  font-size: 1.3rem;
  line-height: 1.3;
  color: var(--teal-light);
}

.product-desc {
  margin-top: 1.25rem;
  max-width: 34rem;
  color: var(--slate-light);
}

.product-facts { margin-top: 1.75rem; max-width: 34rem; }
.product-facts li {
  padding: 0.7rem 0;
  border-top: 1px solid var(--rule-dark);
  color: var(--white);
  font-weight: 500;
  line-height: 1.5;
}
.product-facts li:last-child { border-bottom: 1px solid var(--rule-dark); }

.product-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  margin-top: 2rem;
}

.product-shot { margin: 0; min-width: 0; }

/* Variant switch: same pill control as the language toggle, on dark */
.kv-controls {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 2px;
  border: 1px solid var(--rule-dark);
  border-radius: 999px;
  padding: 2px;
  margin-bottom: 1rem;
}
.kv-controls button {
  font: inherit;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--slate-light);
  background: transparent;
  border: 0;
  border-radius: 999px;
  padding: 0.4rem 1rem;
  cursor: pointer;
  transition: background-color 0.15s, color 0.15s;
}
.kv-controls button:hover { color: var(--white); }
.kv-controls button[aria-pressed="true"] { background: var(--teal-light); color: var(--night); }

.kv-frame {
  border: 1px solid var(--rule-dark);
  border-radius: 14px;
  overflow: hidden;
  background: var(--kv-bg, #0d151b);
  line-height: 0;
}
.kv-frame img { width: 100%; height: auto; }

/* The eight accent colours of the selected variant, on that variant's own background */
.kv-swatches {
  display: grid;
  grid-template-columns: repeat(8, minmax(0, 1fr));
  gap: 0.5rem;
  padding: 0.75rem;
  margin-top: 0.75rem;
  border: 1px solid var(--rule-dark);
  border-radius: 14px;
  background: var(--kv-bg, #0d151b);
}
.kv-swatches span {
  aspect-ratio: 1 / 1;
  border-radius: 0.3em;
  background: var(--c, #888);
}

.product-shot figcaption {
  margin-top: 0.9rem;
  max-width: 40rem;
  font-size: 0.95rem;
  line-height: 1.5;
  color: var(--slate-light);
}

/* ---------- Approach ---------- */

.steps {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 2rem;
}

.steps li {
  padding-top: 1.5rem;
  border-top: 3px solid var(--teal);
}

/* The number sits in a rounded tile, echoing the logo's symbol (radius = 0.3 x tile size). */
.step-no {
  display: grid;
  place-items: center;
  width: 3rem;
  height: 3rem;
  border-radius: 0.9rem;
  background: var(--teal);
  color: var(--white);
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 1.5rem;
  line-height: 1;
  margin-bottom: 1.25rem;
}

.steps h3 {
  font-size: 1.45rem;
  letter-spacing: -0.01em;
  margin-bottom: 0.5rem;
}

/* ---------- Expectations ---------- */

.expect {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  gap: 2rem 4rem;
}

.expect-list { display: grid; gap: 2rem; }
.expect-list h3 {
  font-size: 1.4rem;
  letter-spacing: -0.01em;
  margin-bottom: 0.25rem;
}
.expect-list p { max-width: 32rem; }

/* ---------- Contact ---------- */

.contact {
  background: var(--night);
  color: var(--white);
  padding-block: clamp(4rem, 9vw, 7rem);
}

.contact-inner {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  gap: 3rem 4rem;
  align-items: start;
}

.contact h2 { color: var(--white); }
.contact .lead { color: var(--slate-light); margin-top: 1.25rem; }

.contact-mail {
  margin-top: 2rem;
  font-family: var(--font-heading);
  font-size: 1.4rem;
  font-weight: 500;
}
.contact-mail a {
  text-decoration: none;
  border-bottom: 2px solid var(--teal-light);
}
.contact-mail a:hover { color: var(--teal-light); }

.form { display: grid; gap: 1.25rem; }

.field { display: grid; gap: 0.4rem; }
.field label { font-weight: 600; font-size: 0.95rem; color: var(--white); }

.field input,
.field textarea {
  font: inherit;
  color: var(--ink);
  background: var(--white);
  border: 2px solid transparent;
  border-radius: var(--radius);
  padding: 0.75rem 0.9rem;
  width: 100%;
}
.field textarea { resize: vertical; min-height: 8rem; }
.field input:focus-visible,
.field textarea:focus-visible { outline: 3px solid var(--teal-light); outline-offset: 2px; }
.field [aria-invalid="true"] { border-color: #ffb4a6; }

.form .btn { justify-self: start; }

.form-error { color: #ffb4a6; font-weight: 500; }
.form-note { color: var(--slate-light); font-size: 0.92rem; }

/* ---------- Footer ---------- */

.site-footer {
  background: var(--night);
  color: var(--slate-light);
  border-top: 1px solid var(--rule-dark);
  font-size: 0.95rem;
}
.footer-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem 2rem;
  padding-block: 1.25rem;
}
.footer-logo { width: 170px; height: auto; margin-left: -0.5rem; }

/* ---------- Responsive ---------- */

@media (max-width: 62rem) {
  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2.5rem 2rem; }
  .product { grid-template-columns: minmax(0, 1fr); gap: 2.5rem; }
}

@media (max-width: 56rem) {
  /* not enough room for the 280 px logo plus navigation: use the logo without tagline */
  .nav { display: none; }
  .header-inner { gap: 1rem; min-height: var(--header-h-compact); }
  .brand-full { display: none; }
  .brand-short { display: block; width: 160px; }
  .hero { min-height: min(40rem, calc(100svh - var(--header-h-compact))); }
}

@media (max-width: 48rem) {
  .section-head,
  .service,
  .expect,
  .contact-inner { grid-template-columns: minmax(0, 1fr); }

  .section-head { gap: 1rem; }
  .service { padding-block: 2rem; gap: 1rem; }
  .kv-swatches { gap: 0.35rem; padding: 0.5rem; }
  .steps { grid-template-columns: minmax(0, 1fr); }

  .hero::after {
    background: linear-gradient(0deg, rgba(13, 21, 27, 0.92) 0%, rgba(13, 21, 27, 0.55) 60%, rgba(13, 21, 27, 0.12) 100%);
  }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
