/* =========================================================================
   KAIREXA — Design Tokens & Global Styles
   Concept: "kairos" (the precise moment) + "exa" (scale). The brand idea
   is a software firm that ships at exactly the right moment, at scale.
   Signature element: a live monospace STATUS readout used as a recurring
   eyebrow/tag motif, plus a fine engineering-grid backdrop with a single
   two-stop gradient glow. Everything else stays quiet and disciplined.
   ========================================================================= */

:root{
  /* Color */
  --ink:        #0B0D14; /* base background */
  --surface:    #141826; /* card / panel surface */
  --surface-2:  #1B2033; /* elevated surface, hover states */
  --line:       #262C40; /* hairlines, borders */
  --fog:        #8A93A8; /* secondary text */
  --paper:      #EDEFF5; /* primary text on dark */
  --signal:     #6C5CE7; /* primary accent — violet */
  --pulse:      #2DD4C4; /* secondary accent — teal, gradient partner only */
  --signal-dim: rgba(108, 92, 231, 0.14);
  --gradient:   linear-gradient(135deg, var(--signal) 0%, var(--pulse) 100%);

  /* Type */
  --font-display: "Space Grotesk", "Arial Narrow", sans-serif;
  --font-body:    "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono:    "JetBrains Mono", "SFMono-Regular", Consolas, monospace;

  /* Scale */
  --step-0: clamp(1rem, 0.95rem + 0.2vw, 1.125rem);
  --step-1: clamp(1.25rem, 1.15rem + 0.4vw, 1.5rem);
  --step-2: clamp(1.75rem, 1.5rem + 1vw, 2.25rem);
  --step-3: clamp(2.25rem, 1.8rem + 2vw, 3.25rem);
  --step-4: clamp(3rem, 2.2rem + 3.5vw, 5rem);

  --radius: 10px;
  --container: 1180px;
}

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

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

html{ scroll-behavior: smooth; }

body{
  background: var(--ink);
  color: var(--paper);
  font-family: var(--font-body);
  font-size: var(--step-0);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* Engineering-grid backdrop: fine lines, very low opacity, fixed so it
   reads as a single continuous surface behind every Elementor section. */
body{
  background-image:
    linear-gradient(rgba(255,255,255,0.028) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.028) 1px, transparent 1px);
  background-size: 48px 48px;
  background-attachment: fixed;
}

h1, h2, h3, h4, h5, h6{
  font-family: var(--font-display);
  color: var(--paper);
  line-height: 1.12;
  letter-spacing: -0.01em;
  margin: 0 0 0.5em;
}

h1{ font-size: var(--step-4); font-weight: 600; }
h2{ font-size: var(--step-3); font-weight: 600; }
h3{ font-size: var(--step-2); font-weight: 500; }
h4{ font-size: var(--step-1); font-weight: 500; }

p{ color: var(--fog); margin: 0 0 1em; }

a{ color: var(--paper); text-decoration: none; }

::selection{ background: var(--signal); color: var(--paper); }

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

/* Gradient text utility — used sparingly, once per view max */
.k-gradient-text{
  background: var(--gradient);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* ---- Signature element: the STATUS tag ------------------------------- */
/* A recurring monospace "readout" used as an eyebrow across the site.
   It literalizes the brand idea (Kairexa = shipping at the right moment)
   instead of decorating with an arbitrary numbered marker. */
.k-status{
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--fog);
  border: 1px solid var(--line);
  background: var(--surface);
  padding: 6px 12px 6px 10px;
  border-radius: 999px;
}
.k-status::before{
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--pulse);
  box-shadow: 0 0 0 0 rgba(45, 212, 196, 0.6);
  animation: k-pulse 2.4s ease-out infinite;
}
@keyframes k-pulse{
  0%   { box-shadow: 0 0 0 0 rgba(45, 212, 196, 0.55); }
  70%  { box-shadow: 0 0 0 8px rgba(45, 212, 196, 0); }
  100% { box-shadow: 0 0 0 0 rgba(45, 212, 196, 0); }
}
@media (prefers-reduced-motion: reduce){
  .k-status::before{ animation: none; }
}

/* ---- Layout helpers ---------------------------------------------------- */
.k-container{ max-width: var(--container); margin-inline: auto; padding-inline: 24px; }

.k-card{
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 32px;
  transition: border-color 0.2s ease, transform 0.2s ease;
}
.k-card:hover{
  border-color: var(--signal);
  transform: translateY(-2px);
}

.k-btn{
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.95rem;
  padding: 13px 24px;
  border-radius: 8px;
  border: 1px solid transparent;
  cursor: pointer;
}
.k-btn-primary{
  background: var(--gradient);
  color: var(--ink);
}
.k-btn-primary:hover{ filter: brightness(1.08); }
.k-btn-ghost{
  background: transparent;
  color: var(--paper);
  border-color: var(--line);
}
.k-btn-ghost:hover{ border-color: var(--paper); }

/* ---- Site header / footer (theme-owned, not Elementor) ---------------- */
.k-site-header{
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.k-site-header--static{
  position: static;
  backdrop-filter: none;
}
.k-header-inner{
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-block: 16px;
}
.k-logo{
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.25rem;
  letter-spacing: -0.02em;
}
.k-logo span{ color: var(--pulse); }

.k-nav ul{
  display: flex;
  gap: 32px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.k-nav a{
  font-size: 0.95rem;
  color: var(--fog);
  transition: color 0.15s ease;
}
.k-nav a:hover, .k-nav .current-menu-item a{ color: var(--paper); }

.k-menu-toggle{
  display: none;
  background: none;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--paper);
  padding: 8px 10px;
}

.k-site-footer{
  border-top: 1px solid var(--line);
  padding-block: 48px 28px;
  margin-top: 96px;
}
.k-footer-inner{
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  align-items: center;
  justify-content: space-between;
}
.k-footer-meta{
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--fog);
  letter-spacing: 0.03em;
}
.k-footer-links{ display: flex; gap: 20px; list-style: none; margin: 0; padding: 0; }
.k-footer-links a{ color: var(--fog); font-size: 0.9rem; }
.k-footer-links a:hover{ color: var(--paper); }

@media (max-width: 860px){
  .k-nav{
    display: none;
    position: absolute;
    top: 100%; left: 0; right: 0;
    background: var(--ink);
    border-bottom: 1px solid var(--line);
  }
  .k-nav.is-open{ display: block; }
  .k-nav ul{ flex-direction: column; gap: 0; padding: 8px 24px 20px; }
  .k-nav li{ padding: 12px 0; border-bottom: 1px solid var(--line); }
  .k-menu-toggle{ display: inline-flex; }
}

/* Skip link (accessibility) */
.k-skip-link{
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--paper);
  color: var(--ink);
  padding: 10px 16px;
  z-index: 999;
}
.k-skip-link:focus{ left: 16px; top: 16px; }
