/* =============================================================
   iKITES Services — "Kinetic Precision" design system
   Design tokens are defined as CSS custom properties in :root below.
   ============================================================= */

/* ---------- Design Tokens ---------- */
:root {
  /* Core brand */
  --paper: #ffffff;
  --paper-alt: #eff3f3;
  --navy-deep: #092f4d;
  --slate: #324158;
  --primary: #002540;
  --secondary: #00696c;
  --teal-hover: #1fa7a6;
  --teal-muted: rgba(28, 141, 144, 0.10);
  --text-muted: #5a6b78;

  /* Surfaces & supporting */
  --on-primary: #ffffff;
  --secondary-fixed: #91f2f5;
  --tertiary-fixed: #78f6f5;
  --surface-variant: #d5e5f1;
  --on-tertiary-container: #22b4b4;

  /* Radii */
  --radius-card: 18px;
  --radius-md: 0.75rem;   /* 12px */
  --radius-lg: 1rem;      /* 16px */
  --radius-full: 9999px;

  /* Layout */
  --container-max: 1180px;
  --gutter: 24px;
  --margin-x: 24px;
  --section-pad-v: 100px;
  --section-pad-v-mobile: 60px;

  /* Type families */
  --font-head: "Montserrat", system-ui, sans-serif;
  --font-body: "Open Sans", system-ui, sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, monospace;
}

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

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--slate);
  font-family: var(--font-body);
  font-size: 18px;
  line-height: 28px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

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

h1, h2, h3, h4 { margin: 0; font-family: var(--font-head); color: var(--primary); }
p { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }

button { font-family: inherit; cursor: pointer; }

/* ---------- Layout helpers ---------- */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section { padding-block: var(--section-pad-v); }

/* ---------- Typography scale ---------- */
.eyebrow {
  font-family: var(--font-mono);
  font-size: 14px;
  font-weight: 600;
  line-height: 20px;
  letter-spacing: 0.2em;
  color: var(--secondary);
}

.label-md {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  line-height: 16px;
  letter-spacing: 0.1em;
}

.display-xl {
  font-family: var(--font-head);
  font-size: 72px;
  font-weight: 800;
  line-height: 76px;
  letter-spacing: -0.015em;
}

.headline-lg {
  font-family: var(--font-head);
  font-size: 48px;
  font-weight: 700;
  line-height: 56px;
  letter-spacing: -0.015em;
}

.headline-md {
  font-family: var(--font-head);
  font-size: 32px;
  font-weight: 700;
  line-height: 40px;
  letter-spacing: -0.01em;
}

.headline-sm {
  font-family: var(--font-head);
  font-size: 22px;
  font-weight: 700;
  line-height: 30px;
  letter-spacing: -0.01em;
}

.body-lg { font-size: 20px; line-height: 32px; }
.body-md { font-size: 18px; line-height: 28px; }
.body-sm { font-size: 16px; line-height: 24px; }

.text-secondary { color: var(--secondary); }
.text-muted { color: var(--text-muted); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 0;
  border-radius: var(--radius-full);
  font-family: var(--font-mono);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.2em;
  line-height: 20px;
  padding: 16px 32px;
  transition: background-color .2s ease, color .2s ease, transform .2s ease, box-shadow .2s ease;
}
.btn:active { transform: scale(.96); }

.btn--sm { padding: 10px 24px; }

.btn--primary { background: var(--slate); color: var(--on-primary); }
.btn--primary:hover { background: var(--secondary); transform: translateY(-2px); }

.btn--ghost {
  background: transparent;
  color: var(--slate);
  border: 1px solid var(--slate);
}
.btn--ghost:hover { background: rgba(50, 65, 88, .05); transform: translateY(-2px); }

.btn--accent {
  background: var(--secondary);
  color: var(--on-primary);
  padding: 20px 48px;
  box-shadow: 0 10px 25px rgba(0, 105, 108, .25);
}
.btn--accent:hover { background: var(--teal-hover); transform: translateY(-2px); }

/* ---------- Header / Nav ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  height: 74px;
  background: rgba(255, 255, 255, .82);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(9, 47, 77, .10);
  transition: box-shadow .3s ease;
}
.site-header.is-scrolled { box-shadow: 0 1px 8px rgba(9, 47, 77, .08); }

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}

.brand { display: flex; align-items: center; gap: 10px; }
.brand__logo { height: 34px; width: auto; display: block; }
.brand__name {
  font-family: var(--font-head);
  font-size: 28px;
  font-weight: 700;
  color: var(--primary);
}
.brand__suffix {
  font-family: var(--font-mono);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.2em;
  color: var(--secondary);
  transform: translateY(1px);
}

.nav { display: flex; align-items: center; gap: 32px; }
.nav__link {
  position: relative;
  font-family: var(--font-mono);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.2em;
  color: var(--slate);
  transition: color .2s ease;
}
.nav__link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -6px;
  height: 2px;
  width: 100%;
  background: var(--secondary);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .3s cubic-bezier(.22, 1, .36, 1);
}
.nav__link:hover { color: var(--secondary); }
.nav__link:hover::after { transform: scaleX(1); }

.nav-toggle {
  display: none;
  background: transparent;
  border: 0;
  padding: 8px;
  color: var(--primary);
}
.nav-toggle .material-symbols-outlined { font-size: 28px; }

/* ---------- Hero ---------- */
.hero { padding-top: 80px; padding-bottom: 128px; overflow: hidden; }
.hero__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}
.hero__content { display: flex; flex-direction: column; gap: 32px; }
.hero__title { margin-top: 8px; }
.hero__title .accent { color: var(--secondary); }
.hero__lead { max-width: 36rem; color: rgba(50, 65, 88, .8); }
.hero__actions { display: flex; flex-wrap: wrap; gap: 16px; padding-top: 8px; }

.hero__visual { display: flex; flex-direction: column; align-items: center; }
.hero__panel {
  width: 100%;
  height: 400px;
  border-radius: var(--radius-lg);
  overflow: hidden;
  position: relative;
}
.ascent-glow { filter: drop-shadow(0 0 15px rgba(31, 167, 166, .4)); }
.hero__caption { margin-top: 24px; text-align: center; color: var(--text-muted); }

/* ---------- Trust strip ---------- */
.trust { background: var(--navy-deep); padding-block: 48px; }
.trust__heading {
  margin: 0;
  text-align: center;
  font-family: var(--font-head);
  font-size: 24px;
  font-weight: 700;
  letter-spacing: 0.01em;
  color: var(--on-primary);
}

/* ---------- Generic section heads ---------- */
.section-head { margin-bottom: 64px; }
.section-head--center { text-align: center; }
.section-head--center p { max-width: 48rem; margin-inline: auto; }
.section-head p { color: rgba(50, 65, 88, .7); margin-top: 24px; }

.bg-alt { background: var(--paper-alt); }
.bg-navy { background: var(--navy-deep); color: var(--on-primary); }

/* ---------- The Moment cards ---------- */
.cards-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}
.card {
  padding: 32px;
  border-radius: var(--radius-card);
  border: 1px solid rgba(9, 47, 77, .10);
  background: #fff;
  transition: transform .3s ease, box-shadow .3s ease;
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 40px rgba(9, 47, 77, .15);
}
.card__icon {
  color: var(--secondary);
  font-size: 40px;
  margin-bottom: 24px;
}
.card__title { margin-bottom: 16px; }
.card p { color: rgba(50, 65, 88, .7); }

/* ---------- Capabilities rows ---------- */
.capabilities { display: flex; flex-direction: column; }
.cap-row {
  display: grid;
  grid-template-columns: 3fr 6fr 3fr;
  gap: 32px;
  align-items: start;
  padding-block: 48px;
  border-top: 1px solid rgba(9, 47, 77, .10);
}
.cap-row__body { display: flex; flex-direction: column; gap: 16px; }
.cap-row__body p { color: rgba(50, 65, 88, .8); }
.cap-row__proof-label { color: var(--text-muted); margin-bottom: 8px; }
.cap-row__proof li { color: var(--slate); margin-bottom: 4px; }

/* ---------- Re-engineering (navy split) ---------- */
.reeng__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
}
.reeng__content { display: flex; flex-direction: column; gap: 32px; }
.reeng__content h2 { color: var(--on-primary); }
.reeng__content p { opacity: .8; }
.reeng__link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.2em;
  color: var(--secondary-fixed);
  transition: color .2s ease;
}
.reeng__link:hover { color: var(--tertiary-fixed); }
.reeng__link .material-symbols-outlined { transition: transform .25s cubic-bezier(.22, 1, .36, 1); }
.reeng__link:hover .material-symbols-outlined { transform: translateX(4px); }
.reeng__cards { display: flex; flex-direction: column; gap: 24px; }
.reeng__card {
  padding: 24px;
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, .05);
  border: 1px solid rgba(255, 255, 255, .10);
}
.reeng__card h4 { color: var(--on-primary); margin-bottom: 8px; }
.reeng__card p { opacity: .7; }

/* ---------- Why iKITES ---------- */
.why-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 32px;
}
.why-item { display: flex; flex-direction: column; gap: 16px; }
.why-item__num {
  font-family: var(--font-head);
  font-size: 40px;
  font-weight: 800;
  color: var(--secondary);
}
.why-item p { color: rgba(50, 65, 88, .7); }

/* ---------- Process / How we work ---------- */
.process-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 48px;
}
.process-step { display: flex; flex-direction: column; gap: 24px; }
.process-step__rule { height: 2px; background: var(--secondary); width: 100%; }
.process-step p { color: rgba(50, 65, 88, .7); }

/* ---------- Re-engineering atmospheric texture ---------- */
.reeng-section { position: relative; overflow: hidden; }
.reeng-section::before {
  content: "";
  position: absolute;
  inset: 0;
  background: url("../img/navy-texture.png") right center / cover no-repeat;
  transform: scaleX(-1);          /* flow the schematic lines to the left, away from the cards */
  opacity: .45;
  pointer-events: none;
  z-index: 0;
}
.reeng-section .container { position: relative; z-index: 1; }

/* ---------- CTA band ---------- */
.cta { position: relative; overflow: hidden; padding-block: 96px; }
.cta::before {
  content: "";
  position: absolute;
  inset: 0;
  background: url("../img/navy-texture.png") right center / cover no-repeat;
  opacity: .7;
  pointer-events: none;
  z-index: 0;
}
.cta__glow {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 600px; height: 600px;
  background: rgba(0, 105, 108, .12);
  filter: blur(120px);
  border-radius: var(--radius-full);
  pointer-events: none;
}
.cta__inner { position: relative; z-index: 1; text-align: center; }
.cta__rule {
  display: inline-block;
  width: 96px; height: 2px;
  background: var(--secondary);
  margin-bottom: 48px;
}
.cta h2 { color: var(--on-primary); margin-bottom: 24px; }
.cta__big { color: rgba(255, 255, 255, .9); margin-bottom: 48px; }

/* ---------- Footer ---------- */
.footer { background: var(--navy-deep); padding-block: var(--section-pad-v); border-top: 1px solid rgba(255, 255, 255, .05); }
.footer__grid {
  display: grid;
  grid-template-columns: 5fr 2fr 2fr 3fr;
  gap: 48px;
  color: var(--on-primary);
}
.footer__about { display: flex; flex-direction: column; gap: 24px; }
.footer__about p { opacity: .6; max-width: 20rem; font-size: 16px; line-height: 24px; }
.footer__about .footer__version {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.12em;
  opacity: .4;
}
.footer__brand { display: flex; align-items: center; gap: 10px; }
.footer__brand .brand__logo { height: 38px; }
.footer__brand .brand__name { color: var(--on-primary); }
.footer__col h4 {
  font-family: var(--font-mono);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--secondary);
  margin-bottom: 16px;
}
.footer__col nav { display: flex; flex-direction: column; gap: 8px; }
.footer__col a { opacity: .7; font-size: 16px; transition: color .2s ease, opacity .2s ease; }
.footer__col a:hover { color: var(--secondary); opacity: 1; }
.footer__eco {
  display: block;
  padding: 16px;
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, .05);
  border: 1px solid rgba(255, 255, 255, .10);
  transition: border-color .2s ease;
}
.footer__eco:hover { border-color: var(--secondary); }
.footer__eco-title { color: var(--on-primary); margin-bottom: 4px; }
.footer__eco-desc { opacity: .5; font-size: 13px; line-height: 18px; }

/* ---------- Scroll reveal ---------- */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity .8s cubic-bezier(.22, 1, .36, 1), transform .8s cubic-bezier(.22, 1, .36, 1);
}
.reveal.is-active { opacity: 1; transform: translateY(0); }

/* ---------- Hero entrance (staggered text) ---------- */
.hero--enter .eyebrow,
.hero--enter .text-muted,
.hero--enter .hero__title,
.hero--enter .hero__lead,
.hero--enter .hero__actions {
  animation: heroRise .7s cubic-bezier(.22, 1, .36, 1) both;
}
.hero--enter .eyebrow      { animation-delay: .05s; }
.hero--enter .text-muted   { animation-delay: .15s; }
.hero--enter .hero__title  { animation-delay: .25s; }
.hero--enter .hero__lead   { animation-delay: .35s; }
.hero--enter .hero__actions{ animation-delay: .45s; }

@keyframes heroRise {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: none; }
}

/* Accent underline draws in after the headline settles */
.hero__title .accent { position: relative; white-space: nowrap; }
.hero__title .accent::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: .04em;
  height: 2px;
  background: var(--secondary);
  transform: scaleX(0);
  transform-origin: left;
  animation: underlineDraw .8s cubic-bezier(.22, 1, .36, 1) 1.1s both;
}
@keyframes underlineDraw { to { transform: scaleX(1); } }

/* Hero visual lifts up from the bottom on load, then gently floats */
.hero--enter .hero__visual {
  animation: heroLift 1.1s cubic-bezier(.22, 1, .36, 1) .3s both;
}
.hero--enter .hero__panel {
  animation: heroFloat 7s ease-in-out 1.4s infinite;
}
@keyframes heroLift {
  from { opacity: 0; transform: translateY(64px); }
  to   { opacity: 1; transform: none; }
}
@keyframes heroFloat {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-8px); }
}

/* Material symbols base */
.material-symbols-outlined {
  font-variation-settings: 'FILL' 0, 'wght' 400, 'GRAD' 0, 'opsz' 24;
  vertical-align: middle;
}

/* =============================================================
   Responsive
   ============================================================= */
@media (max-width: 1024px) {
  .display-xl { font-size: 56px; line-height: 60px; }
  .reeng__grid { gap: 48px; }
}

@media (max-width: 900px) {
  :root { --section-pad-v: 60px; }

  .nav { display: none; }
  .nav-toggle { display: inline-flex; }
  .site-header .btn { display: none; }

  /* Mobile nav drawer */
  .nav.is-open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 74px;
    left: 0;
    right: 0;
    gap: 0;
    background: #fff;
    border-bottom: 1px solid rgba(9, 47, 77, .10);
    box-shadow: 0 12px 24px rgba(9, 47, 77, .10);
    padding: 8px 0;
  }
  .nav.is-open .nav__link { padding: 14px var(--gutter); width: 100%; }

  .hero { padding-top: 48px; padding-bottom: 64px; }
  .hero__grid { grid-template-columns: 1fr; gap: 48px; }
  .display-xl { font-size: 44px; line-height: 48px; }
  .headline-lg { font-size: 32px; line-height: 38px; }

  .cards-3 { grid-template-columns: 1fr; }
  .cap-row { grid-template-columns: 1fr; gap: 16px; padding-block: 32px; }
  .reeng__grid { grid-template-columns: 1fr; gap: 40px; }
  .why-grid { grid-template-columns: repeat(2, 1fr); }
  .process-grid { grid-template-columns: 1fr; gap: 40px; }
  .footer__grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 560px) {
  .hero__panel { height: 280px; }
  .why-grid { grid-template-columns: 1fr; }
  .footer__grid { grid-template-columns: 1fr; }
  .btn--accent { padding: 16px 32px; }
}

/* Respect reduced-motion preferences */
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
  .hero--enter .eyebrow,
  .hero--enter .text-muted,
  .hero--enter .hero__title,
  .hero--enter .hero__lead,
  .hero--enter .hero__actions,
  .hero--enter .hero__visual,
  .hero--enter .hero__panel { animation: none; }
  .hero__title .accent::after { animation: none; transform: scaleX(1); }
  .nav__link::after,
  .reeng__link .material-symbols-outlined { transition: none; }
}


/* =============================================================
   Additions — capability cards, slim footer, success stories
   ============================================================= */
.cap-card .eyebrow { display:block; }
.cap-card .card__title { margin-top:14px; }

.footer--slim .container { display:flex; flex-direction:column; gap:20px; }
.footer--slim .footer__brand .brand__logo { height:34px; }
.footer--slim p { color: var(--on-primary); opacity:.55; max-width:46rem; font-size:15px; line-height:24px; }

/* ---- Success Stories page ---- */
.page-hero { padding-top:72px; padding-bottom:8px; }
.page-hero .eyebrow { display:block; margin-bottom:16px; }
.page-hero p { color: rgba(50,65,88,.75); max-width:44rem; margin-top:20px; }

.stories-grid { display:flex; flex-direction:column; gap:28px; }
.story-card {
  border-radius:var(--radius-card);
  border:1px solid rgba(9,47,77,.10); background:#fff;
  display:grid; grid-template-columns:minmax(0,40%) 1fr;
  overflow:hidden;
  transition:transform .3s ease, box-shadow .3s ease;
}
.story-card:hover { transform:translateY(-4px); box-shadow:0 20px 40px rgba(9,47,77,.12); }
.story-card__img {
  display:block;
  width:100%; height:100%;
  min-height:240px;
  object-fit:cover;
  background:var(--navy-deep);
}
.story-card__body {
  display:flex; flex-direction:column; justify-content:center; gap:14px;
  padding:32px 36px;
}
.story-card .tag {
  font-family:var(--font-mono); font-size:12px; font-weight:600;
  letter-spacing:.12em; color:var(--secondary);
}
.story-card h3 { color:var(--primary); }
.story-card p { color:rgba(50,65,88,.72); }

@media (max-width:720px){
  .story-card { grid-template-columns:1fr; }
  .story-card__img { aspect-ratio:16 / 10; min-height:0; height:auto; }
}
