/* ============================================================
   VALOO TECH — valoo.tech
   Design system: carbon + one signal (cyan), monoline geometry.
   Themes via CSS custom properties on html[data-theme].
   ============================================================ */

/* ---------- Tokens ---------- */
:root{
  --cyan:#1AB5E5;
  --cyan-ink:#0E7FA3;
  --carbon:#0B0C0E;
  --white:#FFFFFF;
  --slate:#8A9199;

  --font-display:"Syne",system-ui,sans-serif;
  --font-body:"Manrope",system-ui,-apple-system,"Segoe UI",sans-serif;

  --container:1140px;
  --radius:14px;
  --radius-s:9px;
  --header-h:70px;
}

html[data-theme="dark"]{
  --bg:#0B0C0E;
  --bg-elev:#101318;
  --surface:#12151A;
  --surface-2:#171B21;
  --text:#F2F4F6;
  --text-2:#9AA2AB;
  --text-3:#6E7680;
  --border:#1D2229;
  --border-strong:#2A313A;
  --accent:#1AB5E5;           /* text + graphics on dark: cyan passes contrast */
  --accent-soft:rgba(26,181,229,.10);
  --accent-glow:rgba(26,181,229,.28);
  --btn-primary-text:#06171E;
  --hero-grid:rgba(255,255,255,.035);
  color-scheme:dark;
}
html[data-theme="light"]{
  --bg:#F7F8FA;
  --bg-elev:#FFFFFF;
  --surface:#FFFFFF;
  --surface-2:#F0F2F5;
  --text:#14171A;
  --text-2:#4E5761;
  --text-3:#7A828C;
  --border:#E2E6EB;
  --border-strong:#CBD2DA;
  --accent:#0E7FA3;           /* readable cyan-ink for text/links on light */
  --accent-soft:rgba(26,181,229,.12);
  --accent-glow:rgba(26,181,229,.30);
  --btn-primary-text:#06171E;
  --hero-grid:rgba(11,12,14,.05);
  color-scheme:light;
}

/* ---------- Base ---------- */
*,*::before,*::after{box-sizing:border-box}
html{scroll-behavior:smooth}
html:focus-within{scroll-behavior:smooth}
body{
  margin:0;
  background:var(--bg);
  color:var(--text);
  font-family:var(--font-body);
  font-size:16.5px;
  line-height:1.65;
  -webkit-font-smoothing:antialiased;
  text-rendering:optimizeLegibility;
}
html.theme-x, html.theme-x body, html.theme-x *{
  transition:background-color .25s ease,color .25s ease,border-color .25s ease,fill .25s ease,stroke .25s ease !important;
}
img,svg{display:block;max-width:100%}
a{color:var(--accent);text-decoration:none}
a:hover{text-decoration:underline;text-underline-offset:3px}
::selection{background:var(--cyan);color:#06171E}
:focus-visible{outline:2px solid var(--cyan);outline-offset:3px;border-radius:3px}

.skip-link{
  position:absolute;left:-999px;top:0;z-index:200;
  background:var(--cyan);color:#06171E;padding:.6rem 1rem;border-radius:0 0 8px 0;font-weight:600;
}
.skip-link:focus{left:0}

.container{max-width:var(--container);margin:0 auto;padding:0 clamp(20px,4vw,36px)}

/* ---------- Type ---------- */
h1,h2,h3{font-family:var(--font-display);line-height:1.12;margin:0 0 .6em;letter-spacing:-.01em}
h1{font-weight:800;font-size:clamp(1.9rem,4.4vw,3.1rem)}
h2{font-weight:800;font-size:clamp(1.55rem,3vw,2.2rem)}
h3{font-weight:700;font-size:1.14rem;font-family:var(--font-body);letter-spacing:0}
p{margin:0 0 1em;color:var(--text-2)}
p.lead{font-size:1.12rem}
strong{color:var(--text)}

.eyebrow{
  display:inline-block;
  font-family:var(--font-body);font-weight:700;font-size:.78rem;
  letter-spacing:.24em;text-transform:uppercase;
  color:var(--accent);margin-bottom:1.1rem;
}
.amp{color:var(--cyan)}

/* ---------- Header ---------- */
.site-header{
  position:fixed;inset:0 0 auto 0;z-index:100;height:var(--header-h);
  display:flex;align-items:center;
  background:color-mix(in srgb,var(--bg) 82%,transparent);
  backdrop-filter:blur(14px);-webkit-backdrop-filter:blur(14px);
  border-bottom:1px solid transparent;
  transition:border-color .3s ease;
}
.site-header.scrolled{border-bottom-color:var(--border)}
.header-inner{
  width:100%;max-width:var(--container);margin:0 auto;
  padding:0 clamp(20px,4vw,36px);
  display:flex;align-items:center;gap:1.2rem;
}
.brand-link{display:flex;align-items:center;gap:.7rem;color:var(--text)}
.brand-link:hover{text-decoration:none}
.brandicon{height:30px;width:auto}
.ic-ring{stroke:currentColor;fill:none}
.ic-jewel{stroke:var(--cyan);fill:none}
.brand-name{font-weight:700;font-size:.95rem;letter-spacing:.14em}
.brand-name .tech{color:var(--text-3);font-weight:600}

.main-nav{margin-left:auto;display:flex;align-items:center;gap:1.6rem}
.main-nav a{color:var(--text-2);font-weight:600;font-size:.92rem}
.main-nav a:hover{color:var(--text);text-decoration:none}

.header-tools{display:flex;align-items:center;gap:.55rem;margin-left:.4rem}
.lang-switch{display:flex;align-items:center;border:1px solid var(--border);border-radius:99px;padding:3px}
.lang-switch a{
  padding:.22rem .62rem;border-radius:99px;font-size:.8rem;font-weight:700;
  color:var(--text-3);letter-spacing:.05em;
}
.lang-switch a:hover{text-decoration:none;color:var(--text)}
.lang-switch a.active{background:var(--surface-2);color:var(--text)}

.theme-toggle,.nav-toggle{
  appearance:none;border:1px solid var(--border);background:transparent;color:var(--text-2);
  width:38px;height:38px;border-radius:99px;cursor:pointer;
  display:flex;align-items:center;justify-content:center;
  transition:color .2s,border-color .2s;
}
.theme-toggle:hover,.nav-toggle:hover{color:var(--text);border-color:var(--border-strong)}
.theme-toggle svg{width:17px;height:17px}
html[data-theme="dark"] .icon-sun{display:block}
html[data-theme="dark"] .icon-moon{display:none}
html[data-theme="light"] .icon-sun{display:none}
html[data-theme="light"] .icon-moon{display:block}

.nav-toggle{display:none}
.nav-toggle span,.nav-toggle span::before,.nav-toggle span::after{
  display:block;width:16px;height:2px;background:currentColor;position:relative;transition:transform .25s,opacity .2s;
}
.nav-toggle span::before,.nav-toggle span::after{content:"";position:absolute;left:0}
.nav-toggle span::before{top:-5px}
.nav-toggle span::after{top:5px}
.menu-open .nav-toggle span{transform:rotate(45deg)}
.menu-open .nav-toggle span::before{opacity:0}
.menu-open .nav-toggle span::after{top:0;transform:rotate(-90deg)}

/* ---------- Hero ---------- */
.hero{
  position:relative;
  padding:calc(var(--header-h) + clamp(56px,9vh,110px)) 0 clamp(64px,9vh,110px);
  text-align:center;
  overflow:hidden;
}
.hero::before{ /* faint engineering grid */
  content:"";position:absolute;inset:0;pointer-events:none;
  background-image:
    linear-gradient(var(--hero-grid) 1px,transparent 1px),
    linear-gradient(90deg,var(--hero-grid) 1px,transparent 1px);
  background-size:56px 56px;
  mask-image:radial-gradient(ellipse 90% 70% at 50% 34%,#000 35%,transparent 78%);
  -webkit-mask-image:radial-gradient(ellipse 90% 70% at 50% 34%,#000 35%,transparent 78%);
}
.hero::after{ /* cyan breath behind the mark */
  content:"";position:absolute;left:50%;top:26%;width:min(560px,74vw);aspect-ratio:1.9;
  transform:translate(-50%,-50%);pointer-events:none;
  background:radial-gradient(ellipse at center,var(--accent-glow),transparent 66%);
  opacity:.34;filter:blur(30px);
}
.hero>.container{position:relative;z-index:1}

.wm{width:min(520px,82vw);margin:0 auto 2.4rem;height:auto;color:var(--text)}
.wm-letter{fill:currentColor}
.wm-letter-s,.wm-ring,.wm-tech{stroke:currentColor;fill:none}
.wm-jewel{stroke:var(--cyan);fill:none}

.hero .motto{
  font-weight:700;font-size:clamp(.72rem,1.6vw,.86rem);
  letter-spacing:.3em;text-transform:uppercase;color:var(--text-2);
  margin:0 0 1.6rem;
}
.hero h1{max-width:17ch;margin-left:auto;margin-right:auto}
.hero .lead{max-width:52ch;margin:0 auto 2.2rem}
.cta-row{display:flex;gap:.9rem;justify-content:center;flex-wrap:wrap}

/* Buttons */
.btn{
  display:inline-flex;align-items:center;gap:.5rem;
  font-weight:700;font-size:.95rem;letter-spacing:.02em;
  padding:.82rem 1.5rem;border-radius:var(--radius-s);
  border:1px solid transparent;cursor:pointer;transition:transform .15s ease,box-shadow .2s,background .2s,border-color .2s;
}
.btn:hover{text-decoration:none;transform:translateY(-1px)}
.btn:active{transform:translateY(0)}
.btn-primary{background:var(--cyan);color:var(--btn-primary-text)}
.btn-primary:hover{box-shadow:0 6px 24px -6px var(--accent-glow)}
.btn-ghost{border-color:var(--border-strong);color:var(--text)}
.btn-ghost:hover{border-color:var(--accent);color:var(--accent)}

/* ---------- Hero animation (JS-gated via html.js) ---------- */
html.js .hero .wm-letter,
html.js .hero .wm-letter-s{opacity:0;animation:wmFade .7s cubic-bezier(.2,.7,.2,1) forwards}
html.js .hero .wm-v{animation-delay:.08s}
html.js .hero .wm-a{animation-delay:.2s}
html.js .hero .wm-l{animation-delay:.32s}
html.js .hero .wm-ring{
  stroke-dasharray:100;stroke-dashoffset:100;
  animation:wmDraw 1.05s cubic-bezier(.55,.1,.3,1) forwards;
}
html.js .hero .wm-ring-l{animation-delay:.45s}
html.js .hero .wm-ring-r{animation-delay:.62s}
html.js .hero .wm-jewel{opacity:0;animation:wmJewel .55s ease forwards}
html.js .hero .wm-jewel-1{animation-delay:1.5s}
html.js .hero .wm-jewel-2{animation-delay:1.62s}
html.js .hero .wm-tech{opacity:0;animation:wmFade .8s ease forwards;animation-delay:1.7s}
html.js .hero .motto,
html.js .hero h1,
html.js .hero .lead,
html.js .hero .cta-row{opacity:0;transform:translateY(14px);animation:riseIn .75s cubic-bezier(.2,.7,.2,1) forwards}
html.js .hero .motto{animation-delay:1.9s}
html.js .hero h1{animation-delay:2.02s}
html.js .hero .lead{animation-delay:2.14s}
html.js .hero .cta-row{animation-delay:2.26s}

@keyframes wmFade{from{opacity:0;transform:translateY(10px)}to{opacity:1;transform:none}}
@keyframes wmDraw{to{stroke-dashoffset:0}}
@keyframes wmJewel{
  from{opacity:0;filter:drop-shadow(0 0 0 transparent)}
  60%{opacity:1;filter:drop-shadow(0 0 7px var(--accent-glow))}
  to{opacity:1;filter:drop-shadow(0 0 3px var(--accent-glow))}
}
@keyframes riseIn{to{opacity:1;transform:none}}

/* Scroll reveals */
html.js .reveal{opacity:0;transform:translateY(20px);transition:opacity .7s ease,transform .7s cubic-bezier(.2,.7,.2,1)}
html.js .reveal.in{opacity:1;transform:none}

/* ---------- Sections ---------- */
.section{padding:clamp(64px,10vh,116px) 0;position:relative}
.section-head{max-width:640px;margin-bottom:clamp(2rem,4vw,3rem)}
.section + .section{border-top:1px solid var(--border)}

/* ---------- News ---------- */
.news-strip{padding:clamp(40px,6vh,64px) 0;border-top:1px solid var(--border)}
.news-head{display:flex;align-items:baseline;justify-content:space-between;gap:1rem;margin-bottom:1.6rem}
.news-head .eyebrow{margin-bottom:0}
.news-all{font-weight:700;font-size:.92rem;white-space:nowrap}
.news-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:1.1rem}
.news-card{
  background:var(--surface);border:1px solid var(--border);border-radius:var(--radius);
  padding:1.3rem 1.4rem;display:flex;flex-direction:column;gap:.55rem;
  transition:border-color .25s,transform .2s;
}
.news-card:hover{border-color:var(--accent);transform:translateY(-2px)}
.news-meta{display:flex;align-items:center;gap:.7rem;font-size:.78rem;color:var(--text-3)}
.news-tag{
  color:var(--accent);border:1px solid var(--accent-soft);background:var(--accent-soft);
  padding:.1rem .55rem;border-radius:99px;font-weight:700;letter-spacing:.06em;text-transform:uppercase;font-size:.68rem;
}
.news-card h3{margin:0;font-size:1.04rem}
.news-card p{margin:0;font-size:.94rem;color:var(--text-2)}
.news-card a.title-link{color:var(--text)}
.news-card a.title-link:hover{color:var(--accent);text-decoration:none}
.news-empty{color:var(--text-3);font-size:.95rem}

/* Archive page list */
.archive-list{display:flex;flex-direction:column;gap:1rem;max-width:760px}
.archive-item{
  background:var(--surface);border:1px solid var(--border);border-radius:var(--radius);
  padding:1.3rem 1.5rem;
}
.archive-item h3{margin:.35rem 0 .4rem}
.archive-item p{margin:0}
.page-hero{padding:calc(var(--header-h) + clamp(40px,7vh,72px)) 0 clamp(28px,4vh,44px)}

/* ---------- Services ---------- */
.cards-3{display:grid;grid-template-columns:repeat(3,1fr);gap:1.2rem}
.svc-card{
  background:var(--surface);border:1px solid var(--border);border-radius:var(--radius);
  padding:1.7rem 1.6rem 1.6rem;display:flex;flex-direction:column;gap:.9rem;
  transition:border-color .25s,transform .2s;
}
.svc-card:hover{border-color:var(--border-strong);transform:translateY(-3px)}
.svc-icon{width:56px;height:56px;color:var(--text)}
.svc-icon .st{stroke:currentColor;fill:none;stroke-width:7;stroke-linecap:round;stroke-linejoin:round}
.svc-icon .st-sharp{stroke:currentColor;fill:none;stroke-width:7;stroke-linecap:butt;stroke-linejoin:miter}
.svc-icon .ac{stroke:var(--cyan);fill:none;stroke-width:7;stroke-linecap:round}
.svc-icon .ac-dot{fill:var(--cyan);stroke:none}
.svc-card h3{margin:0}
.svc-card>p{margin:0;font-size:.96rem}
.svc-list{list-style:none;margin:.2rem 0 0;padding:0;display:flex;flex-direction:column;gap:.45rem}
.svc-list li{
  position:relative;padding-left:1.15rem;font-size:.93rem;color:var(--text-2);
}
.svc-list li::before{
  content:"";position:absolute;left:0;top:.52em;width:7px;height:7px;
  border:1.6px solid var(--accent);border-radius:99px;
}

/* ---------- Approach ---------- */
.steps{display:grid;grid-template-columns:repeat(4,1fr);gap:1.2rem;counter-reset:step}
.step{
  border-top:2px solid var(--border-strong);padding-top:1.2rem;position:relative;
}
.step::before{
  content:"";position:absolute;top:-2px;left:0;width:44px;height:2px;background:var(--cyan);
}
.step-num{
  font-family:var(--font-display);font-weight:800;font-size:1.9rem;color:var(--text-3);
  letter-spacing:.02em;line-height:1;margin-bottom:.7rem;
}
.step h3{margin:0 0 .45rem}
.step p{margin:0;font-size:.94rem}

/* ---------- About ---------- */
.about-grid{display:grid;grid-template-columns:1.15fr .85fr;gap:clamp(2rem,5vw,4rem);align-items:center}
.construction{width:100%;max-width:460px;margin:0 auto;color:var(--text)}
.cd-axis{stroke:var(--border-strong);stroke-width:.9;stroke-dasharray:4 4}
.cd-ghost{stroke:var(--border-strong);stroke-width:1;fill:none}
.cd-dot{fill:var(--text-3)}
.cd-cross{fill:var(--cyan)}
.cd-ring{stroke:currentColor;fill:none}
.cd-jewel{stroke:var(--cyan);fill:none}
.about-note{
  margin-top:1.4rem;padding:1.1rem 1.3rem;border-left:2px solid var(--cyan);
  background:var(--surface);border-radius:0 var(--radius-s) var(--radius-s) 0;
  color:var(--text-2);font-size:.97rem;
}
.about-note strong{color:var(--text)}

/* ---------- Contact ---------- */
.contact-grid{display:grid;grid-template-columns:1.05fr .95fr;gap:clamp(2rem,5vw,4rem)}
.contact-form{display:flex;flex-direction:column;gap:1rem}
.field label{display:block;font-weight:600;font-size:.88rem;margin-bottom:.4rem;color:var(--text)}
.field input[type="text"],.field input[type="email"],.field textarea{
  width:100%;background:var(--surface);border:1px solid var(--border);
  color:var(--text);border-radius:var(--radius-s);
  padding:.78rem .95rem;font:inherit;font-size:.97rem;
  transition:border-color .2s;
}
.field textarea{min-height:132px;resize:vertical}
.field input:focus,.field textarea:focus{outline:none;border-color:var(--accent)}
.consent{display:flex;gap:.6rem;align-items:flex-start;font-size:.85rem;color:var(--text-2)}
.consent input{margin-top:.24rem;accent-color:var(--cyan)}
.hp{position:absolute;left:-5000px;width:1px;height:1px;overflow:hidden}
.form-status{display:none;padding:.85rem 1.05rem;border-radius:var(--radius-s);font-size:.93rem;font-weight:600}
.form-status.ok{display:block;background:var(--accent-soft);color:var(--accent);border:1px solid var(--accent)}
.form-status.err{display:block;background:rgba(229,80,57,.1);color:#E06550;border:1px solid #E06550}
.contact-aside h3{margin-top:0}
.contact-lines{list-style:none;padding:0;margin:1rem 0 0;display:flex;flex-direction:column;gap:.7rem}
.contact-lines li{display:flex;gap:.65rem;align-items:baseline;color:var(--text-2);font-size:.96rem}
.contact-lines .k{color:var(--text-3);min-width:74px;font-size:.8rem;font-weight:700;letter-spacing:.08em;text-transform:uppercase}
.ph{color:var(--text-3);font-size:.8rem}

/* ---------- Footer ---------- */
.site-footer{border-top:1px solid var(--border);padding:clamp(44px,7vh,64px) 0 2rem;background:var(--bg-elev)}
.footer-top{display:flex;justify-content:space-between;gap:2rem;align-items:flex-start;flex-wrap:wrap;margin-bottom:2.2rem}
.footer-brand .wm{width:190px;margin:0 0 .9rem;color:var(--text)}
.footer-brand p{font-size:.76rem;letter-spacing:.2em;line-height:1.8;text-transform:uppercase;color:var(--text-3);text-align:left}
.construction-cap{max-width:400px;margin:1.1rem auto 0;text-align:center;font-size:.82rem;line-height:1.5;color:var(--text-3)}
.footer-nav{display:flex;gap:2.6rem;flex-wrap:wrap}
.footer-nav div{display:flex;flex-direction:column;gap:.55rem}
.footer-nav b{font-size:.78rem;letter-spacing:.14em;text-transform:uppercase;color:var(--text-3);font-weight:700;margin-bottom:.15rem}
.footer-nav a{color:var(--text-2);font-size:.92rem}
.footer-nav a:hover{color:var(--text);text-decoration:none}
.footer-bottom{
  border-top:1px solid var(--border);padding-top:1.4rem;
  display:flex;justify-content:space-between;gap:1rem;flex-wrap:wrap;
  color:var(--text-3);font-size:.83rem;
}
.footer-bottom .legal{max-width:70ch}

/* ---------- Responsive ---------- */
@media (max-width:960px){
  .cards-3{grid-template-columns:1fr 1fr}
  .steps{grid-template-columns:1fr 1fr;row-gap:2rem}
  .about-grid,.contact-grid{grid-template-columns:1fr}
  .construction{max-width:380px}
}
@media (max-width:760px){
  .nav-toggle{display:flex}
  .main-nav{
    position:fixed;inset:var(--header-h) 0 auto 0;
    flex-direction:column;align-items:flex-start;gap:0;
    background:var(--bg-elev);border-bottom:1px solid var(--border);
    padding:.6rem clamp(20px,4vw,36px) 1rem;
    transform:translateY(-8px);opacity:0;pointer-events:none;
    transition:transform .25s ease,opacity .25s ease;
  }
  .menu-open .main-nav{transform:none;opacity:1;pointer-events:auto}
  .main-nav a{padding:.7rem 0;width:100%;border-bottom:1px solid var(--border);font-size:1rem}
  .main-nav a:last-child{border-bottom:0}
  .news-grid,.cards-3{grid-template-columns:1fr}
  .steps{grid-template-columns:1fr}
  .hero{text-align:left}
  .hero .wm{margin-left:0}
  .hero h1,.hero .lead{margin-left:0}
  .cta-row{justify-content:flex-start}
  .hero::after{left:38%}
  .footer-top{flex-direction:column}
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion:reduce){
  html{scroll-behavior:auto}
  *,*::before,*::after{animation:none !important;transition:none !important}
  html.js .hero .wm-letter,html.js .hero .wm-letter-s,html.js .hero .wm-tech,
  html.js .hero .wm-jewel,html.js .hero .motto,html.js .hero h1,
  html.js .hero .lead,html.js .hero .cta-row{opacity:1;transform:none}
  html.js .hero .wm-ring{stroke-dashoffset:0}
  html.js .reveal{opacity:1;transform:none}
}
