/*
Theme Name: INKA TechEngg
Theme URI: https://inkatechengg.com
Author: INKA TechEngg Consulting Pvt. Ltd.
Description: Custom full-site-editing block theme for INKA TechEngg — engineering and technology consulting across defence, infrastructure and industrial sectors. Built from the INKA homepage design: dark "field-ready" hero and defence sections, light advisory sections, and a monospace HUD accent typeface for labels and controls.
Version: 1.9.0
Requires at least: 6.4
Tested up to: 6.7
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: inka-techengg
*/

/* ---------- Base ---------- */
html { scroll-behavior: smooth; }
body { margin: 0; background: #2b2b29; }
a { text-decoration: none; }
section[id] { scroll-margin-top: 88px; }
.inka-hud, .has-hud-font-family { letter-spacing: .06em; }

/* ---------- Site frame ---------- */
.inka-frame {
  max-width: 1400px;
  margin: 0 auto;
  background: #232321;
  border-radius: 2px;
  box-shadow: 0 20px 60px rgba(0,0,0,.5);
}
/* WP's default flow-layout blockGap adds a 24px top margin to every direct
   child of every "is-layout-flow" block, site-wide (frame sections, card
   copy, etc.). Spacing here is controlled explicitly per element instead. */
.wp-site-blocks .is-layout-flow > *:not(.inka-hud) { margin-block-start: 0px !important; }

/* ---------- Buttons ----------
   Styling lives on .wp-block-button__link (the inner <a>) only — the
   outer .wp-block-button wrapper stays unstyled so padding isn't applied
   twice (wrapper + link) and doubled up. */
.inka-btn:not(.wp-block-button),
.inka-btn .wp-block-button__link {
  position: relative;
  display: inline-block;
  font-family: var(--wp--preset--font-family--hud);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: .07em;
  padding: 16px 34px;
  border: 1px solid transparent;
  border-radius: 0 !important;
  cursor: pointer;
}
.inka-btn-primary:not(.wp-block-button),
.inka-btn-primary .wp-block-button__link { background: #2f6ca8 !important; color: #fff !important; }
.inka-btn-primary:not(.wp-block-button):hover,
.inka-btn-primary .wp-block-button__link:hover { background: #1c4470 !important; color: #fff !important; }
.inka-btn-secondary:not(.wp-block-button),
.inka-btn-secondary .wp-block-button__link {
  background: rgba(47,108,168,.16) !important;
  border-color: #2f6ca8 !important;
  color: #9dc3e8 !important;
}
.inka-btn-secondary:not(.wp-block-button):hover,
.inka-btn-secondary .wp-block-button__link:hover { background: rgba(47,108,168,.32) !important; }
.inka-btn-small:not(.wp-block-button),
.inka-btn-small .wp-block-button__link {
  padding: 11px 20px !important;
  font-size: 12.5px;
}
.inka-btn-small { flex-shrink: 0; }
.inka-text-link {
  font-family: var(--wp--preset--font-family--hud);
  font-size: 12.5px;
  letter-spacing: .07em;
  color: #2f6ca8 !important;
  border-bottom: 1px solid #2f6ca8;
  padding-bottom: 3px;
}

/* ---------- Nav ---------- */
/* The <header> wrapping .inka-nav has no other content, so it's exactly
   nav's height — sticky needs its containing block to be taller than the
   element itself, or there's no scroll range to stick within. Sticking the
   header (whose real parent, .inka-frame, spans the whole page) instead of
   the nav div fixes that. */
.inka-header {
  position: sticky;
  top: 0;
  z-index: 60;
}
.inka-nav {
  display: flex;
  align-items: center;
  gap: 60px;
  padding: 14px 32px;
  background: #0a1119;
  border-bottom: 1px solid #1d2c3c;
  flex-wrap: wrap;
  box-sizing: border-box;
}
.inka-nav-logo img { height: 44px; width: auto; display: block; }
.inka-nav-links {
  display: flex;
  align-items: center;
  gap: 30px;
  flex: 1;
  flex-wrap: wrap;
}
.inka-nav-links a {
  font-family: var(--wp--preset--font-family--hud);
  color: #c6cdd6 !important;
  font-size: 12.5px;
  letter-spacing: .07em;
}
.inka-nav-links a:hover { color: #9dc3e8 !important; }

/* Hamburger toggle + mobile overlay menu */
.inka-nav-links .wp-block-navigation__responsive-container-open,
.inka-nav-links .wp-block-navigation__responsive-container-close {
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 8px;
}
.inka-nav-links .wp-block-navigation__responsive-container.is-menu-open {
  font-family: var(--wp--preset--font-family--hud);
}
.inka-nav-links .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation-item__content {
  font-size: 15px;
  letter-spacing: .07em;
  padding: 14px 0;
}

/* ---------- Eyebrow labels ---------- */
.inka-eyebrow {
  font-family: var(--wp--preset--font-family--hud);
  font-size: 12.5px;
  letter-spacing: .09em;
  margin-bottom: 26px;
}

/* ---------- Hero ---------- */
.inka-hero { background: #0a1119; }

/* One-screen hero: nav (54px) + slider (fixed 360px) + stats strip +
   heading/description/buttons all fit within 100vh, no scrolling. Desktop
   and tablet only — see the mobile override below. */
@media (min-width: 769px) {
  .inka-hero {
    height: calc(100vh - 34px);
    display: flex;
    flex-direction: column;
    overflow: hidden;
  }
  .inka-hero-media { flex-shrink: 0; }
  .inka-stats-strip { flex-shrink: 0; }
  .inka-hero-content {
    flex: 1 1 auto;
    min-height: 0;
    overflow: hidden;
  }
}
.inka-hero-media {
  position: relative;
  height: 360px;
  min-height: 360px;
  overflow: hidden;
  border-bottom: 1px solid #1d2c3c;
}
.inka-hero-slider,
.inka-hero-slider .kt-blocks-gallery-figure {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  margin: 0;
}
/* Multiple slides stack on top of each other; a small script (functions.php)
   toggles .is-active to crossfade between them every 5s, pausing on hover. */
.inka-hero-slider .kt-blocks-gallery-item {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  opacity: 0;
  z-index: 0;
  transition: opacity 1s ease;
}
.inka-hero-slider .kt-blocks-gallery-item.is-active {
  opacity: 1;
  z-index: 1;
}
.inka-hero-slider img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  filter: brightness(.62) saturate(.75) contrast(1.05);
}
/* Transparent product-shot graphics (e.g. the drone silhouette) shouldn't be
   cropped by cover-fit or dimmed by the photo-darkening filter. */
.inka-hero-slider .is-contain img {
  object-fit: contain;
  filter: none;
  background: #0a1119;
}
.inka-hero-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(10,17,25,.55) 0%, rgba(10,17,25,.12) 35%, rgba(10,17,25,.7) 100%);
}
/* HUD markers overlaid on the hero image — each is its own block in the
   editor (select it in List View to delete it, or use the block's own
   Dimensions → Margin controls to nudge its on-screen position). */
.inka-hud { position: absolute; z-index: 5; }
/* HUD markers only belong on the first hero slide (the drone shot) — the
   slider JS toggles .is-first-slide on #inka-hero-media to match. */
.inka-hero-media:not(.is-first-slide) .inka-hud { display: none; }

.inka-hud-rec {
  right: 24px; top: 24px;
  display: flex; align-items: center; gap: 8px;
  background: rgba(10,17,25,.65); border: 1px solid #2f6ca8;
  padding: 6px 12px; color: #e8eef4; font-size: 12px; letter-spacing: .06em;
  font-family: var(--wp--preset--font-family--hud);
}
.inka-hud-rec span {
  width: 7px; height: 7px; border-radius: 50%; background: #4a90d9; display: inline-block;
}

.inka-hud-compass {
  top: 34px; left: 50%; transform: translateX(-50%);
  display: flex; flex-direction: column; align-items: center; gap: 5px;
}
.inka-hud-compass-label {
  color: #e8eef4; font-family: var(--wp--preset--font-family--hud);
  font-size: 11px; letter-spacing: .1em; margin: 0 !important;
}
.inka-hud-compass-ticks { display: flex; align-items: flex-end; gap: 7px; height: 12px; }
.inka-hud-compass-ticks span { width: 1px; height: 6px; background: #9fb0c2; display: inline-block; }
.inka-hud-compass-ticks span.is-center { height: 12px; background: #fff; }

.inka-hud-reticle {
  left: 50%; top: 52%; transform: translate(-50%,-50%);
  width: 180px; height: 180px;
}
.inka-hud-reticle-line { position: absolute; background: #4a90d9; }
.inka-hud-reticle-line.is-top { left: 50%; top: 0; width: 1px; height: 56px; transform: translateX(-50%); }
.inka-hud-reticle-line.is-bottom { left: 50%; bottom: 0; width: 1px; height: 56px; transform: translateX(-50%); }
.inka-hud-reticle-line.is-left { top: 50%; left: 0; height: 1px; width: 56px; transform: translateY(-50%); }
.inka-hud-reticle-line.is-right { top: 50%; right: 0; height: 1px; width: 56px; transform: translateY(-50%); }
.inka-hud-reticle-box {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%,-50%);
  width: 44px; height: 44px; border: 1px solid #4a90d9; background: rgba(74,144,217,.28);
}

/* Minimal scanning-border loop: a short, faint segment continuously
   traces the box outline. Kept subtle — small arc, muted, slow. */
.inka-hud-rec,
.inka-hud-reticle-box {
  position: absolute;
}
.inka-hud-rec::before,
.inka-hud-reticle-box::before {
  content: "";
  position: absolute;
  inset: -1px;
  padding: 1px;
  background: conic-gradient(transparent 88%, rgba(122,182,240,.6) 96%, transparent 100%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  animation: inka-hud-scan 6s linear infinite;
  pointer-events: none;
}
@keyframes inka-hud-scan {
  to { transform: rotate(360deg); }
}
@media (prefers-reduced-motion: reduce) {
  .inka-hud-rec::before,
  .inka-hud-reticle-box::before { animation: none; }
}
.inka-stats-strip {
  display: grid; grid-template-columns: repeat(3, 1fr);
  border-bottom: 1px solid #1d2c3c;
  font-family: var(--wp--preset--font-family--hud);
  color: #aab6c4; font-size: 12.5px; letter-spacing: .06em;
}
.inka-stats-strip > * { padding: 16px 36px; border-left: 1px solid #1d2c3c; margin: 0; }
.inka-stats-strip > *:first-child { border-left: none; }
.inka-hero-content {
  display: grid; grid-template-columns: 1.15fr 1fr;
}
.inka-hero-content-copy { padding: 36px; }
.inka-hero-content-desc {
  padding: 36px; border-left: 1px solid #1d2c3c; background: #08101a;
  display: flex; flex-direction: column; justify-content: center;
  gap: 24px;
}
.inka-hero-content-desc > * { margin: 0; padding-bottom: 0; }

/* ---------- Section rhythm ---------- */
.inka-section-light { background: #f7f9fb; padding: 88px 36px; border-top: 1px solid #d3dae2; }
.inka-section-steel { background: #eef1f5; padding: 88px 36px; border-top: 1px solid #d3dae2; }
.inka-section-dark { background: #0a1119; padding: 88px 36px; border-top: 1px solid #1d2c3c; }

/* ---------- About ---------- */
.inka-about-grid { display: grid; grid-template-columns: 1.25fr 1fr; gap: 64px; align-items: stretch; }
.inka-about-image-frame {
  border: 1px solid #d3dae2;
  background: #fff;
  padding: 18px;
  display: flex;
  flex-direction: column;
}
.inka-about-image-frame .wp-block-image,
.inka-about-image-frame .inka-photo-fill {
  flex: 1;
  min-height: 0;
  overflow: hidden;
  margin: 0;
}
.inka-about-image-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top;
  display: block;
}
.inka-about-caption {
  font-family: var(--wp--preset--font-family--hud);
  margin-top: 16px; color: #2f6ca8; font-size: 11.5px; letter-spacing: .07em;
}
.inka-tag-row {
  font-family: var(--wp--preset--font-family--hud);
  display: flex; gap: 32px; flex-wrap: wrap; margin-top: 34px;
  border-top: 1px solid #d3dae2; padding-top: 22px; color: #6b7887;
  font-size: 12.5px; letter-spacing: .07em;
}

/* ---------- Services ---------- */
.inka-service-row {
  display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center;
  padding: 52px 0; border-bottom: 1px solid #d3dae2;
}
.inka-service-row:last-child { border-bottom: none; }
.inka-service-row.is-reversed .inka-service-copy { order: 2; }
.inka-service-row.is-reversed .inka-service-image { order: 1; }
.inka-service-index {
  font-family: var(--wp--preset--font-family--hud);
  color: #2f6ca8; font-size: 12.5px; letter-spacing: .08em; margin-bottom: 16px;
}
.inka-service-image { border: 1px solid #d3dae2; background: #fff; padding: 16px; }
.inka-service-image img { width: 100%; height: 320px; object-fit: cover; display: block; }
.inka-service-tags {
  font-family: var(--wp--preset--font-family--hud);
  display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 24px;
}
.inka-tag {
  position: relative;
  display: inline-block;
  border: 1px solid #b9c8d8; color: #2f6ca8; font-size: 11.5px;
  letter-spacing: .06em; padding: 7px 12px;
}

/* ---------- Infrastructure ---------- */
.inka-infra-intro { display: grid; grid-template-columns: 1.15fr 1fr; gap: 64px; align-items: stretch; }
.inka-infra-image-frame {
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.inka-infra-image-frame .wp-block-image,
.inka-infra-image-frame .inka-photo-fill { margin: 0; }
.inka-infra-image-frame img {
  width: 100%;
  height: auto;
  display: block;
}
.inka-infra-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px;
  background: #1d2c3c; margin-top: 1px;
}
.inka-infra-card { background: #0a1119; padding: 34px 30px; }
.inka-infra-index {
  font-family: var(--wp--preset--font-family--hud);
  color: #4a90d9; font-size: 12.5px; letter-spacing: .08em; margin-bottom: 14px;
}

/* ---------- Contact ---------- */
.inka-contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; }
.inka-contact-links {
  font-family: var(--wp--preset--font-family--hud);
  display: flex; flex-direction: column; gap: 12px; font-size: 14px;
  letter-spacing: .04em; border-top: 1px solid #1d2c3c; padding-top: 24px;
}
.inka-contact-links a { color: #9dc3e8 !important; }
.inka-form { display: flex; flex-direction: column; gap: 14px; }
.inka-form input,
.inka-form textarea {
  border: 1px solid #1d2c3c; background: #0a1119; padding: 15px 16px;
  font-size: 14px; color: #f3f6fa; font-family: inherit; width: 100%;
  box-sizing: border-box;
}
.inka-form textarea { resize: vertical; }
.inka-form button { align-self: flex-start; }
.inka-form-notice { font-size: 14px; padding: 12px 16px; margin-bottom: 6px; font-family: var(--wp--preset--font-family--hud); }
.inka-form-notice.is-success { background: rgba(74,144,217,.16); border: 1px solid #2f6ca8; color: #9dc3e8; }
.inka-form-notice.is-error { background: rgba(200,80,80,.12); border: 1px solid #a84a4a; color: #e8b3b3; }

/* ---------- Footer ---------- */
.inka-footer {
  background: #1c4470; border-top: 1px solid #2f6ca8; padding: 30px 36px;
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 16px;
  color: #c9dcf0; font-size: 12.5px;
}
.inka-footer a { color: #c9dcf0 !important; }
.inka-footer-meta { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .inka-hero-content,
  .inka-about-grid,
  .inka-infra-intro,
  .inka-service-row,
  .inka-contact-grid { grid-template-columns: 1fr; }
  .inka-service-row.is-reversed .inka-service-copy,
  .inka-service-row.is-reversed .inka-service-image { order: initial; }
  .inka-hero-content-desc { border-left: none; border-top: 1px solid #1d2c3c; }
  .inka-infra-grid { grid-template-columns: 1fr; }
  .inka-stats-strip { grid-template-columns: 1fr; }
  .inka-stats-strip > * { border-left: none; border-top: 1px solid #1d2c3c; }
  .inka-stats-strip > *:first-child { border-top: none; }
}
@media (max-width: 600px) {
  .inka-section-light, .inka-section-steel, .inka-section-dark { padding: 56px 20px; }
  .inka-nav { padding: 12px 20px; gap: 16px; }
  .inka-nav-links { gap: 16px; }
}

/* Mobile: drop the boxed frame, run edge-to-edge */
@media (max-width: 768px) {
  body { background: #0a1119; }
  .inka-frame {
    max-width: none;
    margin: 0;
    background: transparent;
    border-radius: 0;
    box-shadow: none;
  }

  /* Readability: mobile headings run too tight/too large at desktop sizes */
  .wp-block-heading {
    line-height: 1.3 !important;
    text-align: left !important;
  }
  .has-xx-large-font-size { font-size: 28px !important; }
  .wp-block-paragraph, p { text-align: left; }

  .inka-section-light, .inka-section-steel, .inka-section-dark, .inka-footer {
    padding-left: 20px !important;
    padding-right: 20px !important;
  }

  /* Contact CTA next to the hamburger is redundant with the CONTACT menu link */
  .inka-nav-cta { display: none !important; }

  /* Hamburger toggle: right-aligned with breathing room from the edge,
     instead of hugging the logo at the start of its flex:1 container. */
  .inka-nav-links {
    justify-content: flex-end;
  }
  .inka-nav-links .wp-block-navigation__responsive-container-open {
    margin-right: 4px;
  }

  /* Mobile menu overlay: left padding so links aren't flush against the edge */
  .inka-nav-links .wp-block-navigation__responsive-container.is-menu-open {
    padding-left: 20px;
    padding-right: 20px;
  }
  .inka-nav-links .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__responsive-container-close {
    margin-right: 4px;
  }
}

.has-body-light-color { padding-bottom: 10px; }

/* ---------- Border-scan hover effect ----------
   A soft glowing dot with a fading trailing tail travels each box's
   border while hovered. Pure CSS via offset-path — no markup changes;
   applies to every button and tag pill through ::before/::after. */
.inka-btn:not(.wp-block-button)::before,
.inka-btn .wp-block-button__link::before,
.inka-tag::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 10px;
  height: 10px;
  margin: -5px 0 0 -5px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(122,182,240,.85) 0%, rgba(74,144,217,.45) 45%, transparent 75%);
  filter: blur(1px);
  offset-path: border-box;
  offset-distance: 0%;
  opacity: 0;
  transition: opacity .5s ease;
  pointer-events: none;
  z-index: 2;
  animation-name: inka-border-scan;
  animation-timing-function: linear;
  animation-iteration-count: infinite;
  animation-play-state: paused;
  animation-duration: 6s;
}
.inka-btn:not(.wp-block-button)::after,
.inka-btn .wp-block-button__link::after,
.inka-tag::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 26px;
  height: 2px;
  margin-top: -1px;
  background: linear-gradient(to left, rgba(160,205,245,.9) 0%, rgba(74,144,217,.35) 55%, transparent 100%);
  offset-path: border-box;
  offset-anchor: 100% 50%;
  offset-rotate: auto;
  offset-distance: 0%;
  opacity: 0;
  transition: opacity .5s ease;
  pointer-events: none;
  z-index: 1;
  animation-name: inka-border-scan;
  animation-timing-function: linear;
  animation-iteration-count: infinite;
  animation-play-state: paused;
  animation-duration: 6s;
}
.inka-tag::before, .inka-tag::after { animation-duration: 4s; }
.inka-btn-small:not(.wp-block-button)::before,
.inka-btn-small:not(.wp-block-button)::after,
.inka-btn-small .wp-block-button__link::before,
.inka-btn-small .wp-block-button__link::after { animation-duration: 3s; }

.inka-btn:not(.wp-block-button):hover::before,
.inka-btn:not(.wp-block-button):hover::after,
.inka-btn .wp-block-button__link:hover::before,
.inka-btn .wp-block-button__link:hover::after,
.inka-tag:hover::before,
.inka-tag:hover::after {
  opacity: 1;
  animation-play-state: running;
}
@keyframes inka-border-scan {
  to { offset-distance: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  .inka-btn:not(.wp-block-button)::before,
  .inka-btn:not(.wp-block-button)::after,
  .inka-btn .wp-block-button__link::before,
  .inka-btn .wp-block-button__link::after,
  .inka-tag::before,
  .inka-tag::after {
    animation: none !important;
    opacity: 0 !important;
  }
}

