/* --------------------------------------------------------------------------
   UNION MECHANICS - STYLE SYSTEM
   Theme: High-Tech Dark Mechatronics
   -------------------------------------------------------------------------- */

/* CSS Variables */
:root {
  --bg-primary: #07111f;
  --bg-secondary: #0b1728;
  --bg-tertiary: #12233a;
  --accent-primary: #4dd9ff;
  --accent-primary-rgb: 77, 217, 255;
  --accent-secondary: #5f8cff;
  --accent-secondary-rgb: 95, 140, 255;
  --text-primary: #f8fafc;
  --text-secondary: #aabbd0;
  --text-muted: #74869d;
  --glass-bg: rgba(12, 28, 47, 0.78);
  --glass-border: rgba(164, 208, 255, 0.13);
  --glass-border-hover: rgba(77, 217, 255, 0.42);
  --shadow-glow: 0 24px 70px rgba(0, 12, 30, 0.42);
  --header-bg: rgba(7, 17, 31, 0.82);
  --grid-line: rgba(132, 183, 237, 0.055);
  --section-tint: rgba(14, 34, 57, 0.66);
  --button-ink: #04111f;
  --font-sans: "Outfit", sans-serif;
  --transition-smooth: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  --transition-fast: all 0.18s ease;
}

html[data-theme="light"] {
  --bg-primary: #eef4fb;
  --bg-secondary: #f7faff;
  --bg-tertiary: #e4edf8;
  --text-primary: #0c1b2e;
  --text-secondary: #40536a;
  --text-muted: #62758b;
  --glass-bg: rgba(255, 255, 255, 0.78);
  --glass-border: rgba(18, 52, 85, 0.12);
  --glass-border-hover: rgba(0, 126, 184, 0.38);
  --shadow-glow: 0 24px 70px rgba(24, 57, 91, 0.14);
  --header-bg: rgba(247, 250, 255, 0.84);
  --grid-line: rgba(43, 99, 151, 0.07);
  --section-tint: rgba(255, 255, 255, 0.56);
  --accent-primary: #007fa8;
  --accent-primary-rgb: 0, 127, 168;
  --accent-secondary: #245ee8;
  --accent-secondary-rgb: 36, 94, 232;
  --button-ink: #ffffff;
}

/* Reset & Base Styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 96px;
  font-size: 16px;
  background-color: var(--bg-primary);
  color: var(--text-primary);
  font-family: var(--font-sans);
}

body {
  overflow-x: hidden;
  line-height: 1.6;
  min-height: 100vh;
  background: var(--bg-primary);
  color: var(--text-primary);
  -webkit-font-smoothing: antialiased;
}

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

body.nav-open {
  overflow: hidden;
}

/* Scrollbar Customization */
::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background: var(--bg-primary);
}
::-webkit-scrollbar-thumb {
  background: var(--bg-tertiary);
  border-radius: 4px;
  border: 2px solid var(--bg-primary);
}
::-webkit-scrollbar-thumb:hover {
  background: var(--accent-primary);
  box-shadow: 0 0 10px var(--accent-primary);
}

/* Global Container */
.container {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding-inline: clamp(1.25rem, 4vw, 2rem);
}

/* Typography & Headers */
h1,
h2,
h3,
h4,
h5,
h6 {
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: 0;
}

p {
  color: var(--text-secondary);
  font-weight: 300;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.8rem 2rem;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  font-weight: 600;
  border-radius: 8px;
  cursor: pointer;
  transition: var(--transition-smooth);
  text-decoration: none;
  border: 2px solid transparent;
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
.btn:focus-visible {
  outline: 3px solid rgba(var(--accent-primary-rgb), 0.75);
  outline-offset: 4px;
}

.btn:disabled {
  cursor: not-allowed;
  opacity: 0.65;
  transform: none;
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent-primary), #3b82f6);
  color: #0b0f19;
  box-shadow: 0 4px 15px rgba(0, 240, 255, 0.25);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 240, 255, 0.4);
  filter: brightness(1.1);
}

.btn-outline {
  background: transparent;
  border-color: var(--glass-border);
  color: var(--text-primary);
}

.btn-outline:hover {
  border-color: var(--accent-primary);
  color: var(--accent-primary);
  box-shadow: var(--shadow-glow);
  transform: translateY(-2px);
}

.btn-block {
  display: flex;
  width: 100%;
}

/* Gradient Text */
.gradient-text {
  background: linear-gradient(
    135deg,
    var(--text-primary) 30%,
    var(--accent-primary) 100%
  );
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* Glass Panels & Cards */
.glass-panel {
  background: var(--glass-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--glass-border);
  border-radius: 8px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.glass-card {
  background: var(--glass-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--glass-border);
  border-radius: 8px;
  padding: 2.25rem;
  transition: var(--transition-smooth);
  position: relative;
  overflow: hidden;
}

.glass-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: radial-gradient(
    800px circle at var(--mouse-x, 0) var(--mouse-y, 0),
    rgba(var(--accent-primary-rgb), 0.06),
    transparent 40%
  );
  z-index: 1;
  pointer-events: none;
}

.glass-card:hover {
  transform: translateY(-3px);
  border-color: var(--glass-border-hover);
  box-shadow: var(--shadow-glow);
}

/* Header & Navigation */
#main-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 100;
  transition: var(--transition-smooth);
}

.header-transparent {
  padding: 1.15rem 0;
  background: transparent;
}

.header-scrolled {
  padding: 0.55rem 0;
  background: rgba(11, 15, 25, 0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--glass-border);
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.2);
}

.nav-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo-link {
  display: flex;
  align-items: center;
  flex: 0 0 auto;
}

.main-logo {
  height: 64px;
  width: 64px;
  object-fit: contain;
  transition: var(--transition-smooth);
}

.header-scrolled .main-logo {
  height: 54px;
  width: 54px;
}

.desktop-nav ul {
  display: flex;
  list-style: none;
  gap: 1.45rem;
}

.desktop-nav a {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 500;
  transition: var(--transition-fast);
  position: relative;
  padding: 0.5rem 0;
}

.desktop-nav a:hover,
.desktop-nav a.active {
  color: var(--accent-primary);
}

.desktop-nav a::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--accent-primary);
  transition: var(--transition-smooth);
}

.desktop-nav a:hover::after,
.desktop-nav a.active::after {
  width: 100%;
}

.header-controls {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

/* Language Selector */
.lang-switch-wrapper {
  position: relative;
}

.lang-toggle-btn {
  background: var(--bg-tertiary);
  border: 1px solid var(--glass-border);
  color: var(--text-secondary);
  font-family: var(--font-sans);
  font-size: 0.8rem;
  font-weight: 700;
  padding: 0.4rem 0.8rem;
  border-radius: 20px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.3rem;
  transition: var(--transition-fast);
}

.lang-toggle-btn:hover {
  border-color: var(--accent-primary);
  color: var(--text-primary);
  box-shadow: 0 0 10px rgba(0, 240, 255, 0.1);
}

.lang-toggle-btn .active-lang {
  color: var(--accent-primary);
}

.lang-toggle-btn .lang-divider {
  color: var(--text-muted);
}

.lang-toggle-btn .inactive-lang {
  opacity: 0.6;
}

/* Mobile Menu Toggle */
.mobile-nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 24px;
  height: 18px;
  background: transparent;
  border: none;
  cursor: pointer;
  z-index: 110;
}

.hamburger-bar {
  width: 100%;
  height: 2px;
  background-color: var(--text-primary);
  border-radius: 2px;
  transition: var(--transition-smooth);
}

.mobile-nav-toggle[aria-expanded="true"] .hamburger-bar:nth-child(1) {
  transform: translateY(8px) rotate(45deg);
}

.mobile-nav-toggle[aria-expanded="true"] .hamburger-bar:nth-child(2) {
  opacity: 0;
}

.mobile-nav-toggle[aria-expanded="true"] .hamburger-bar:nth-child(3) {
  transform: translateY(-8px) rotate(-45deg);
}

/* Mobile Navigation Drawer */
.mobile-nav-drawer {
  position: fixed;
  top: 0;
  right: -100%;
  width: 300px;
  height: 100vh;
  background: rgba(11, 15, 25, 0.95);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-left: 1px solid var(--glass-border);
  padding: 8rem 2rem 2rem;
  z-index: 90;
  transition: var(--transition-smooth);
  visibility: hidden;
}

.mobile-nav-drawer.active {
  right: 0;
  visibility: visible;
}

.mobile-nav ul {
  display: flex;
  flex-direction: column;
  list-style: none;
  gap: 2rem;
}

.mobile-nav a {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 1.25rem;
  font-weight: 500;
  transition: var(--transition-fast);
  display: block;
}

.mobile-nav a:hover,
.mobile-nav a.active {
  color: var(--accent-primary);
  padding-left: 0.5rem;
}

/* Hero Section */
.hero-section {
  position: relative;
  min-height: clamp(660px, 88svh, 860px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8.25rem 0 5.5rem;
  overflow: hidden;
}

.hero-bg-visual {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 100%;
  max-width: 880px;
  height: 100%;
  opacity: 0.15;
  pointer-events: none;
  z-index: 1;
}

/* Radar SVG Animation */
.radar-grid {
  width: 100%;
  height: 100%;
}

.radar-circle {
  fill: none;
  stroke: var(--accent-primary);
  stroke-width: 1px;
  transform-origin: center;
}

.circle-1 {
  animation: pulse 6s infinite ease-in-out;
}
.circle-2 {
  animation: pulse 8s infinite ease-in-out 1.5s;
}
.circle-3 {
  animation: pulse 10s infinite ease-in-out 3s;
}

.radar-line {
  stroke: var(--accent-primary);
  stroke-width: 0.5px;
  opacity: 0.3;
}

.radar-sweep {
  fill: url(#radar-gradient);
  stroke: var(--accent-primary);
  stroke-width: 1.5px;
  opacity: 0.8;
  transform-origin: 400px 400px;
  animation: rotate-radar 12s linear infinite;
}

.radar-target {
  fill: var(--accent-secondary);
  box-shadow: 0 0 10px var(--accent-secondary);
  animation: blink-target 3s infinite ease-in-out;
}

.target-1 {
  animation-delay: 0.5s;
}
.target-2 {
  animation-delay: 1.8s;
  fill: var(--accent-primary);
}

@keyframes pulse {
  0% {
    transform: scale(0.9);
    opacity: 0.2;
  }
  50% {
    transform: scale(1.05);
    opacity: 0.8;
  }
  100% {
    transform: scale(0.9);
    opacity: 0.2;
  }
}

@keyframes rotate-radar {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

@keyframes blink-target {
  0%,
  100% {
    opacity: 0.2;
    transform: scale(0.8);
  }
  50% {
    opacity: 1;
    transform: scale(1.2);
  }
}

.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 920px;
}

.hero-tagline {
  position: relative;
  display: inline-flex;
  align-items: center;
  background: rgba(0, 240, 255, 0.06);
  border: 1px solid rgba(0, 240, 255, 0.2);
  padding: 0.4rem 1.2rem;
  border-radius: 30px;
  margin-bottom: 2rem;
}

.hero-tagline span {
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  color: var(--accent-primary);
}

.hero-tagline .tagline-glow {
  position: absolute;
  width: 6px;
  height: 6px;
  background: var(--accent-primary);
  border-radius: 50%;
  left: 8px;
  box-shadow: 0 0 10px var(--accent-primary);
  animation: pulse-glow 2s infinite;
}

@keyframes pulse-glow {
  0%,
  100% {
    opacity: 0.4;
  }
  50% {
    opacity: 1;
  }
}

.hero-section h1 {
  font-size: clamp(2.75rem, 5vw, 4.15rem);
  font-weight: 800;
  margin-bottom: 1.5rem;
  letter-spacing: 0;
  text-wrap: balance;
}

.hero-section p {
  font-size: clamp(1.05rem, 1.6vw, 1.2rem);
  margin-bottom: 2.5rem;
  max-width: 720px;
  text-wrap: pretty;
}

.hero-ctas {
  display: flex;
  gap: 1.5rem;
}

.scroll-down-indicator {
  position: absolute;
  bottom: 2.5rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  opacity: 1;
  transition: opacity 0.45s ease;
}

.scroll-down-indicator.is-fading {
  opacity: 0;
  pointer-events: none;
}

.mouse-icon {
  display: block;
  width: 26px;
  height: 42px;
  border: 2px solid var(--text-secondary);
  border-radius: 15px;
  position: relative;
  opacity: 0.6;
  transition: var(--transition-fast);
}

.mouse-icon:hover {
  opacity: 1;
  border-color: var(--accent-primary);
}

.mouse-icon .wheel {
  display: block;
  width: 4px;
  height: 8px;
  background-color: var(--accent-primary);
  border-radius: 2px;
  position: absolute;
  top: 8px;
  left: 50%;
  transform: translateX(-50%);
  animation: scroll-wheel 1.8s infinite ease-in-out;
}

@keyframes scroll-wheel {
  0% {
    transform: translate(-50%, 0);
    opacity: 0;
  }
  30% {
    opacity: 1;
  }
  100% {
    transform: translate(-50%, 15px);
    opacity: 0;
  }
}

/* General Sections */
section {
  padding: clamp(4.25rem, 7vw, 6rem) 0;
  position: relative;
}

.section-header {
  text-align: center;
  margin-bottom: clamp(2.75rem, 5vw, 4.5rem);
}

.section-title {
  font-size: 2.5rem;
  font-weight: 800;
  margin-bottom: 0.8rem;
  letter-spacing: 0;
}

.section-underline {
  width: 60px;
  height: 4px;
  background: linear-gradient(
    90deg,
    var(--accent-primary),
    var(--accent-secondary)
  );
  margin: 0 auto;
  border-radius: 2px;
}

.section-intro {
  max-width: 680px;
  margin: 1.25rem auto 0;
  font-size: 1.05rem;
}

/* About Us Section */
.about-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 4rem;
  align-items: center;
}

.about-text-content h3 {
  font-size: 1.8rem;
  margin-bottom: 1.5rem;
}

.about-text-content p {
  margin-bottom: 1.5rem;
  font-size: 1.05rem;
}

.about-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  margin-top: 3rem;
}

.stat-item {
  display: flex;
  flex-direction: column;
}

.stat-number {
  font-size: 2.5rem;
  font-weight: 800;
  line-height: 1;
  margin-bottom: 0.5rem;
}

.stat-label {
  font-size: 0.85rem;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.about-visual-container {
  display: flex;
  justify-content: center;
  align-items: center;
}

.about-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  width: min(100%, 390px);
  min-height: 410px;
  padding: 3.2rem 2.5rem;
  position: relative;
  border-color: rgba(16, 185, 129, 0.2);
}

.logo-fallback-wrapper {
  width: 180px;
  height: 180px;
  border-radius: 50%;
  background: radial-gradient(
    circle,
    rgba(var(--accent-primary-rgb), 0.16),
    rgba(16, 185, 129, 0.05) 68%
  );
  border: 1px solid rgba(var(--accent-primary-rgb), 0.26);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 2.4rem;
  box-shadow: 0 0 42px rgba(var(--accent-primary-rgb), 0.12);
}

.about-logo-icon {
  width: 132px;
  height: 132px;
  object-fit: contain;
}

.about-card h4 {
  font-size: 1.7rem;
  margin-bottom: 1rem;
}

.about-card-desc {
  font-size: 1rem;
  max-width: 300px;
}

.collaborations-section {
  padding-top: 3.5rem;
  background: linear-gradient(
    180deg,
    var(--bg-primary),
    rgba(19, 27, 46, 0.45)
  );
}

.collaboration-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.25rem;
  width: 100%;
  list-style: none;
}

.collaboration-grid > li {
  min-width: 0;
}

.collaboration-item {
  min-height: 178px;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 0.85rem;
  padding: 1.2rem;
  color: var(--text-primary);
  font-weight: 700;
  text-decoration: none;
  border: 1px solid var(--glass-border);
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.58);
  transition: var(--transition-fast);
}

.collaboration-item:hover {
  border-color: var(--glass-border-hover);
  background: rgba(19, 27, 46, 0.78);
  transform: translateY(-2px);
}

.collaboration-logo {
  width: 100%;
  max-width: 220px;
  height: 86px;
  object-fit: contain;
  padding: 0.8rem;
  border-radius: 6px;
  background: transparent;
}

.collaboration-logo--light {
  background: rgba(255, 255, 255, 0.96);
}

.collaboration-item span {
  color: var(--text-secondary);
  font-size: 0.88rem;
}

.projects-empty {
  max-width: 720px;
  margin: 0 auto;
  padding: clamp(2rem, 5vw, 3.5rem);
  text-align: center;
}

.projects-empty-logo {
  width: 72px;
  height: 72px;
  object-fit: contain;
  margin-bottom: 1.5rem;
}

.projects-empty h2 {
  font-size: 2rem;
  margin-bottom: 1rem;
}

.projects-empty p {
  max-width: 560px;
  margin: 0 auto 1rem;
  font-size: 1.05rem;
}

.projects-actions,
.contact-actions {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 2rem;
}

/* Services Section */
.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.service-card {
  display: flex;
  flex-direction: column;
  z-index: 10;
}

.service-icon-wrapper {
  width: 60px;
  height: 60px;
  background: rgba(0, 240, 255, 0.05);
  border: 1px solid rgba(0, 240, 255, 0.15);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 2rem;
  color: var(--accent-primary);
  transition: var(--transition-smooth);
}

.service-card:hover .service-icon-wrapper {
  background: var(--accent-primary);
  color: #0b0f19;
  box-shadow: 0 0 15px rgba(0, 240, 255, 0.4);
  transform: scale(1.05);
}

.service-icon {
  width: 28px;
  height: 28px;
}

.service-card h3 {
  font-size: 1.4rem;
  margin-bottom: 1rem;
}

.service-card p {
  font-size: 0.95rem;
  margin-bottom: 2rem;
  flex-grow: 1;
}

.service-link {
  color: var(--accent-primary);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.9rem;
  transition: var(--transition-fast);
}

.service-link:hover {
  color: var(--text-primary);
  letter-spacing: 0.05em;
}

/* Technical Details Section (Interactive Tabs) */
.tabs-container {
  padding: 2.5rem;
}

.tabs-nav {
  display: flex;
  justify-content: center;
  border-bottom: 1px solid var(--glass-border);
  margin-bottom: 3rem;
  gap: 1rem;
}

.tab-btn {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  font-family: var(--font-sans);
  font-size: 1.1rem;
  font-weight: 600;
  padding: 1rem 2rem;
  cursor: pointer;
  transition: var(--transition-fast);
  position: relative;
}

.tab-btn::after {
  content: "";
  position: absolute;
  bottom: -1px;
  left: 0;
  width: 0;
  height: 3px;
  background: var(--accent-primary);
  transition: var(--transition-smooth);
}

.tab-btn:hover {
  color: var(--text-primary);
}

.tab-btn.active {
  color: var(--accent-primary);
}

.tab-btn.active::after {
  width: 100%;
}

.tab-panel {
  display: none;
}

.tab-panel[hidden] {
  display: none;
}

.tab-panel.active {
  display: block;
  animation: fadeInTab 0.5s ease forwards;
}

@keyframes fadeInTab {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.panel-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 4rem;
  align-items: center;
}

.panel-info h3 {
  font-size: 1.8rem;
  margin-bottom: 1.5rem;
}

.panel-info p {
  font-size: 1.05rem;
  margin-bottom: 1.5rem;
}

.specs-list {
  list-style: none;
  margin-top: 2rem;
}

.specs-list li {
  display: flex;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  padding: 0.8rem 0;
  font-size: 0.95rem;
}

.specs-list li strong {
  width: 180px;
  color: var(--text-primary);
  flex-shrink: 0;
}

.specs-list li span {
  color: var(--text-secondary);
}

.panel-visual {
  display: flex;
  justify-content: center;
}

.sketch-container {
  width: 100%;
  max-width: 380px;
  border: 1px solid var(--glass-border);
  border-radius: 12px;
  background: rgba(15, 23, 42, 0.5);
  padding: 1.5rem;
  box-shadow: inset 0 0 20px rgba(0, 0, 0, 0.2);
}

.sketch-svg {
  width: 100%;
  height: auto;
  display: block;
}

/* Code Terminal Mockup */
.code-terminal {
  background: #090d16;
  border-color: rgba(56, 189, 248, 0.15);
  font-family: "Courier New", Courier, monospace;
  padding: 0;
  overflow: hidden;
}

.terminal-header {
  background: #0f172a;
  padding: 0.6rem 1rem;
  display: flex;
  align-items: center;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.terminal-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  margin-right: 0.4rem;
}

.terminal-dot.red {
  background: #ef4444;
}
.terminal-dot.yellow {
  background: #f59e0b;
}
.terminal-dot.green {
  background: #10b981;
}

.terminal-title {
  color: var(--text-muted);
  font-size: 0.75rem;
  margin-left: 1rem;
}

.terminal-body {
  padding: 1.5rem;
  font-size: 0.85rem;
  overflow-x: auto;
}

.code-keyword {
  color: #f472b6;
}
.code-string {
  color: #34d399;
}
.code-comment {
  color: var(--text-muted);
}
.code-type {
  color: #60a5fa;
}
.code-func {
  color: #fb7185;
}
.code-var {
  color: #fbbf24;
}

/* Blinking LED Board Animation */
.blinking-led {
  animation: led-blink 1s infinite alternate;
}

@keyframes led-blink {
  0% {
    opacity: 0.3;
    filter: drop-shadow(0 0 1px #ef4444);
  }
  100% {
    opacity: 1;
    filter: drop-shadow(0 0 6px #ef4444);
  }
}

/* Contact Section */
.contact-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 4rem;
  align-items: start;
}

.contact-info-panel h2,
.contact-info-panel h3 {
  font-size: 1.8rem;
  margin-bottom: 1.5rem;
}

.contact-info-panel p {
  font-size: 1.05rem;
  margin-bottom: 3rem;
}

.contact-details-list {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.contact-detail-item {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.detail-icon-wrapper {
  width: 50px;
  height: 50px;
  background: rgba(0, 240, 255, 0.05);
  border: 1px solid rgba(0, 240, 255, 0.15);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-primary);
}

.detail-icon {
  width: 22px;
  height: 22px;
}

.detail-text {
  display: flex;
  flex-direction: column;
}

.detail-label {
  font-size: 0.8rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.detail-value {
  font-size: 1.05rem;
  font-weight: 500;
  color: var(--text-primary);
}

.contact-form-wrapper {
  padding: 3rem;
}

.contact-action-card {
  padding: clamp(2rem, 5vw, 3rem);
  text-align: center;
}

.contact-eyebrow {
  display: inline-block;
  margin-bottom: 1rem;
  color: var(--accent-primary);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.contact-action-card h2 {
  margin-bottom: 1rem;
  font-size: clamp(1.7rem, 3vw, 2.35rem);
}

.contact-action-card > p {
  max-width: 520px;
  margin: 0 auto;
}

.copy-feedback {
  min-height: 1.5rem;
  margin-top: 1rem;
  color: var(--accent-secondary);
  font-size: 0.9rem;
}

.form-group {
  margin-bottom: 1.8rem;
}

.form-group label {
  display: block;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 0.6rem;
}

.form-group input,
.form-group textarea {
  width: 100%;
  background: rgba(11, 15, 25, 0.5);
  border: 1px solid var(--glass-border);
  border-radius: 8px;
  padding: 0.85rem 1.2rem;
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 0.95rem;
  transition: var(--transition-fast);
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--accent-primary);
  box-shadow: 0 0 10px rgba(0, 240, 255, 0.15);
  background: rgba(11, 15, 25, 0.8);
}

.form-note {
  color: var(--text-muted);
  font-size: 0.85rem;
  margin: -0.4rem 0 1.4rem;
}

.form-group input.invalid,
.form-group textarea.invalid {
  border-color: #ef4444;
  box-shadow: 0 0 10px rgba(239, 68, 68, 0.15);
}

.form-feedback {
  margin-top: 1.5rem;
  font-size: 0.95rem;
  text-align: center;
  min-height: 24px;
  transition: var(--transition-fast);
}

.form-feedback.success {
  color: var(--accent-secondary);
}

.form-feedback.error {
  color: #ef4444;
}

/* Footer */
footer {
  padding: 4rem 0;
  background: #070a11;
  border-top: 1px solid var(--glass-border);
}

.footer-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
  text-align: center;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  font-size: 1.4rem;
  font-weight: 700;
}

.footer-logo {
  height: 30px;
  width: 30px;
  object-fit: contain;
}

.footer-text {
  font-size: 0.85rem;
  color: var(--text-muted);
  max-width: 600px;
}

/* Scroll-Reveal animations (Intersection Observer) */
.scroll-reveal {
  opacity: 1;
  transform: none;
}

.js .scroll-reveal {
  opacity: 0;
  transform: translateY(30px);
  transition:
    opacity 0.8s ease,
    transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.js .scroll-reveal.revealed {
  opacity: 1;
  transform: translateY(0);
}

/* Responsive Design */
@media (max-width: 1024px) {
  .about-grid,
  .panel-grid,
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 3rem;
  }

  .about-visual-container {
    order: -1;
  }

  .panel-visual {
    order: -1;
    max-width: 100%;
  }

  .sketch-container {
    max-width: 100%;
  }

  .services-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .collaboration-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  section {
    padding: 5rem 0;
  }
}

@media (max-width: 768px) {
  html {
    font-size: 15px;
    scroll-padding-top: 82px;
  }

  .container {
    padding: 0 1.25rem;
  }

  .header-transparent,
  .header-scrolled {
    padding: 0.65rem 0;
    background: rgba(11, 15, 25, 0.9);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--glass-border);
  }

  .desktop-nav {
    display: none;
  }

  .mobile-nav-toggle {
    display: flex;
  }

  .mobile-nav-drawer {
    width: min(320px, 86vw);
    padding: 7rem 1.5rem 2rem;
  }

  .hero-section {
    min-height: auto;
    padding: 7.5rem 0 4.5rem;
  }

  .hero-section h1 {
    font-size: 2.35rem;
    line-height: 1.12;
  }

  .hero-section p {
    font-size: 1.05rem;
    margin-bottom: 2rem;
  }

  .hero-tagline {
    margin-bottom: 1.5rem;
    max-width: 100%;
  }

  .hero-tagline span {
    font-size: 0.7rem;
    letter-spacing: 0.08em;
  }

  .hero-ctas {
    width: 100%;
    flex-direction: column;
    gap: 0.9rem;
  }

  .hero-ctas .btn {
    width: 100%;
  }

  .scroll-down-indicator {
    display: none;
  }

  section {
    padding: 4rem 0;
  }

  .section-header {
    margin-bottom: 3rem;
  }

  .section-title {
    font-size: 2rem;
  }

  .services-grid {
    grid-template-columns: 1fr;
    gap: 1.25rem;
  }

  .glass-card {
    padding: 1.6rem;
  }

  .service-icon-wrapper {
    width: 52px;
    height: 52px;
    margin-bottom: 1.25rem;
  }

  .service-card h3 {
    font-size: 1.2rem;
  }

  .service-card p {
    margin-bottom: 1.3rem;
  }

  .collaboration-grid {
    grid-template-columns: 1fr;
  }

  .collaboration-item {
    min-height: 154px;
  }

  .projects-actions,
  .contact-actions {
    flex-direction: column;
  }

  .projects-actions .btn,
  .contact-actions .btn {
    width: 100%;
  }

  .about-stats {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .tabs-nav {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    margin-bottom: 2rem;
  }

  .tab-btn {
    padding: 0.8rem;
    font-size: 1rem;
  }

  .tab-btn::after {
    bottom: 0;
    left: 0;
    width: 3px !important;
    height: 0;
    top: 0;
  }

  .tab-btn.active::after {
    height: 100%;
    width: 3px !important;
  }

  .tabs-container {
    padding: 1.25rem;
  }

  .panel-grid {
    gap: 2rem;
  }

  .panel-info h3 {
    font-size: 1.45rem;
  }

  .panel-info p {
    font-size: 1rem;
  }

  .sketch-container {
    padding: 1rem;
  }

  .contact-form-wrapper {
    padding: 2rem 1.5rem;
  }

  .projects-empty {
    padding: 2rem 1.25rem;
  }

  .projects-empty h2 {
    font-size: 1.55rem;
  }

  .contact-detail-item {
    align-items: flex-start;
    gap: 1rem;
  }

  .detail-value {
    overflow-wrap: anywhere;
  }

  .specs-list li {
    flex-direction: column;
    gap: 0.3rem;
  }

  .specs-list li strong {
    width: 100%;
  }

  .page-banner {
    padding-top: 115px;
    padding-bottom: 2.25rem;
  }

  .page-banner h1 {
    font-size: 2.25rem;
  }

  .cta-section-subpage {
    padding: 4rem 0;
  }

  .cta-section-subpage h2 {
    font-size: 1.8rem;
  }
}

/* --------------------------------------------------------------------------
   Integrated capabilities, services and project portfolio
   -------------------------------------------------------------------------- */
.section-space {
  padding-block: clamp(4.5rem, 9vw, 7.5rem);
}

.section-heading {
  max-width: 760px;
  margin: 0 auto clamp(2.25rem, 5vw, 4rem);
  text-align: center;
}

.section-kicker {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--accent-primary);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.15em;
}

.section-kicker::before {
  width: 0.45rem;
  height: 0.45rem;
  border-radius: 50%;
  background: var(--accent-primary);
  box-shadow: 0 0 0.8rem rgba(var(--accent-primary-rgb), 0.45);
  content: "";
}

.section-heading h2 {
  margin-top: 0.75rem;
  font-size: clamp(2rem, 4vw, 3.1rem);
}

.section-intro {
  max-width: 760px;
  margin: 1rem auto 0;
  font-size: clamp(1rem, 1.75vw, 1.2rem);
  line-height: 1.75;
}

.home-capabilities-section {
  position: relative;
  border-top: 1px solid var(--glass-border);
  background: linear-gradient(180deg, var(--bg-primary), #0c1321 62%, var(--bg-primary));
}

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

.pillar-card {
  display: flex;
  min-width: 0;
  min-height: 20rem;
  flex-direction: column;
  padding: clamp(1.45rem, 2.5vw, 2rem);
  border: 1px solid var(--glass-border);
  border-radius: 1rem;
  background: linear-gradient(155deg, rgba(21, 32, 53, 0.96), rgba(14, 21, 35, 0.9));
}

.pillar-card:hover {
  border-color: var(--glass-border-hover);
  transform: translateY(-5px);
}

.pillar-number,
.project-index,
.sector-index,
.process-step-number {
  display: inline-flex;
  width: fit-content;
  align-items: center;
  justify-content: center;
  color: var(--accent-primary);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.11em;
}

.pillar-number {
  min-width: 2.45rem;
  height: 2.45rem;
  margin-bottom: auto;
  border: 1px solid rgba(var(--accent-primary-rgb), 0.35);
  border-radius: 0.7rem;
  background: rgba(var(--accent-primary-rgb), 0.07);
}

.pillar-card h3 {
  margin-top: 2rem;
  font-size: clamp(1.2rem, 2vw, 1.45rem);
}

.pillar-card p {
  margin-top: 0.9rem;
  font-size: 0.98rem;
  line-height: 1.7;
}

.capability-tags,
.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1.5rem;
  list-style: none;
}

.capability-tags {
  margin-top: auto;
  padding-top: 1.35rem;
}

.capability-tags li,
.project-tags li {
  padding: 0.28rem 0.55rem;
  border: 1px solid rgba(var(--accent-primary-rgb), 0.22);
  border-radius: 999px;
  color: #c6f8fc;
  background: rgba(var(--accent-primary-rgb), 0.07);
  font-size: 0.76rem;
  line-height: 1.25;
}

.section-anchor-nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.6rem;
  margin: 1.75rem auto 0;
}

.section-anchor-nav a {
  padding: 0.45rem 0.85rem;
  border: 1px solid var(--glass-border);
  border-radius: 999px;
  color: var(--text-secondary);
  font-size: 0.9rem;
  font-weight: 600;
  text-decoration: none;
  transition: var(--transition-fast);
}

.section-anchor-nav a:hover {
  border-color: rgba(var(--accent-primary-rgb), 0.48);
  color: var(--accent-primary);
}

.services-banner,
.portfolio-banner {
  padding-bottom: clamp(2.5rem, 5vw, 4rem);
}

.services-banner .container,
.portfolio-banner .container {
  text-align: center;
}

.sectors-section {
  border-block: 1px solid var(--glass-border);
  background: linear-gradient(120deg, rgba(19, 27, 46, 0.45), rgba(11, 15, 25, 0.2));
}

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

.sector-card {
  position: relative;
  min-width: 0;
  padding: clamp(1.5rem, 3vw, 2.25rem);
  overflow: hidden;
}

.sector-card::after {
  position: absolute;
  top: 0;
  right: 0;
  width: 7rem;
  height: 7rem;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(var(--accent-primary-rgb), 0.12), transparent 68%);
  content: "";
  pointer-events: none;
}

.sector-index {
  opacity: 0.75;
}

.sector-card h3 {
  margin-top: 1rem;
  font-size: clamp(1.25rem, 2vw, 1.55rem);
}

.sector-card p {
  max-width: 44rem;
  margin-top: 0.75rem;
}

.sector-card ul {
  display: grid;
  gap: 0.45rem;
  margin-top: 1.15rem;
  padding-left: 1.15rem;
  color: #c8d6eb;
}

.sector-card li::marker {
  color: var(--accent-primary);
}

.process-section {
  background: var(--bg-primary);
}

.process-timeline {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 0.75rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.process-timeline li {
  position: relative;
  min-width: 0;
  padding: 1.15rem 0.85rem 0;
  border-top: 1px solid rgba(var(--accent-primary-rgb), 0.38);
}

.process-timeline li::before {
  position: absolute;
  top: -0.28rem;
  left: 0;
  width: 0.48rem;
  height: 0.48rem;
  border-radius: 50%;
  background: var(--accent-primary);
  box-shadow: 0 0 0.7rem rgba(var(--accent-primary-rgb), 0.7);
  content: "";
}

.process-step-number {
  color: var(--text-muted);
}

.process-timeline h3 {
  margin-top: 0.65rem;
  font-size: 1.02rem;
}

.process-timeline p {
  margin-top: 0.45rem;
  font-size: 0.88rem;
  line-height: 1.55;
}

.integration-callout {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  margin-top: clamp(2.5rem, 6vw, 4.5rem);
  padding: clamp(1.3rem, 3vw, 2rem);
}

.integration-callout p {
  max-width: 48rem;
  font-size: 1.05rem;
}

.portfolio-section {
  padding-block: clamp(3.5rem, 7vw, 6.5rem);
}

.portfolio-feature {
  display: grid;
  grid-template-columns: minmax(16rem, 0.85fr) minmax(0, 1.15fr);
  align-items: stretch;
  gap: clamp(1.25rem, 3vw, 2.5rem);
  padding: clamp(1rem, 2.75vw, 2rem);
}

.portfolio-feature-copy,
.portfolio-card-copy {
  display: flex;
  min-width: 0;
  flex-direction: column;
  justify-content: center;
}

.portfolio-feature h2,
.portfolio-card h2 {
  margin-top: 0.85rem;
  font-size: clamp(1.5rem, 3vw, 2.2rem);
}

.portfolio-feature p,
.portfolio-card p {
  margin-top: 0.9rem;
  line-height: 1.72;
}

.portfolio-feature-gallery,
.portfolio-card-gallery {
  display: grid;
  min-width: 0;
  gap: 0.7rem;
}

.gallery-trigger {
  display: block;
  min-width: 0;
  border: 0;
  border-radius: 0.75rem;
  background: #08101e;
  cursor: zoom-in;
  overflow: hidden;
}

.gallery-trigger img {
  width: 100%;
  height: 100%;
  min-height: 0;
  object-fit: cover;
  transition: transform 0.35s ease;
}

.gallery-trigger:hover img {
  transform: scale(1.035);
}

.gallery-trigger--main {
  aspect-ratio: 16 / 10;
}

.gallery-trigger--main img {
  object-position: center 45%;
}

.portfolio-thumbs {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.7rem;
}

.portfolio-thumbs .gallery-trigger {
  aspect-ratio: 1 / 0.8;
}

.portfolio-thumbs .gallery-trigger:first-child img {
  object-position: center 36%;
}

.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.5rem;
  margin-top: 1.5rem;
}

.portfolio-card {
  display: grid;
  grid-template-columns: minmax(0, 0.86fr) minmax(11rem, 1.14fr);
  min-width: 0;
  min-height: 21rem;
  gap: 1.2rem;
  padding: clamp(1rem, 2.25vw, 1.5rem);
}

.portfolio-card--text {
  grid-template-columns: 1fr;
  min-height: 15rem;
}

.portfolio-card h2 {
  font-size: clamp(1.25rem, 2vw, 1.6rem);
}

.portfolio-card p {
  font-size: 0.94rem;
}

.portfolio-card-gallery--two {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.portfolio-card-gallery--single {
  grid-template-columns: minmax(0, 1fr);
}

.portfolio-card-gallery--single .gallery-trigger {
  min-height: 100%;
}

.portfolio-card-gallery--two .gallery-trigger {
  min-height: 100%;
}

.portfolio-card-gallery--two .gallery-trigger:last-child img {
  object-position: center top;
}

.portfolio-card--software {
  grid-column: 1 / -1;
  grid-template-columns: minmax(0, 0.86fr) minmax(15rem, 1.14fr);
}

.software-surface {
  display: grid;
  min-height: 15rem;
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: auto auto 1fr;
  gap: 0.7rem;
  padding: 1.2rem;
  border: 1px solid rgba(var(--accent-primary-rgb), 0.23);
  border-radius: 0.75rem;
  background:
    linear-gradient(rgba(0, 240, 255, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 240, 255, 0.05) 1px, transparent 1px),
    linear-gradient(140deg, #0e1d31, #08101e);
  background-size: 1.75rem 1.75rem, 1.75rem 1.75rem, auto;
}

.software-surface > span {
  display: block;
  height: 3.5rem;
  border: 1px solid rgba(var(--accent-primary-rgb), 0.22);
  border-radius: 0.55rem;
  background: linear-gradient(135deg, rgba(0, 240, 255, 0.22), rgba(48, 123, 255, 0.08));
}

.software-line {
  grid-column: 1 / -1;
  width: 70%;
  height: 0.55rem;
  border-radius: 999px;
  background: rgba(170, 231, 247, 0.35);
}

.software-line--wide { width: 92%; }
.software-line--short { width: 45%; }

.software-chart {
  display: flex;
  grid-column: 1 / -1;
  align-items: end;
  gap: 0.6rem;
  margin-top: auto;
  padding-top: 1rem;
  border-top: 1px solid rgba(var(--accent-primary-rgb), 0.18);
}

.software-chart i {
  display: block;
  width: 14%;
  border-radius: 0.25rem 0.25rem 0 0;
  background: linear-gradient(180deg, var(--accent-primary), #2879e8);
}

.software-chart i:nth-child(1) { height: 31%; }
.software-chart i:nth-child(2) { height: 55%; }
.software-chart i:nth-child(3) { height: 42%; }
.software-chart i:nth-child(4) { height: 78%; }
.software-chart i:nth-child(5) { height: 64%; }

.service-link {
  margin-top: 1.4rem;
}

.portfolio-cta {
  max-width: 760px;
  margin: clamp(3rem, 7vw, 5rem) auto 0;
  text-align: center;
}

.portfolio-cta p {
  font-size: 1.1rem;
}

.portfolio-cta .btn {
  margin-top: 1.5rem;
}

.project-lightbox {
  width: min(94vw, 74rem);
  max-width: none;
  max-height: 94vh;
  margin: auto;
  padding: 0;
  border: 1px solid rgba(var(--accent-primary-rgb), 0.3);
  border-radius: 1rem;
  background: #09111f;
  color: var(--text-primary);
  box-shadow: 0 1.25rem 5rem rgba(0, 0, 0, 0.58);
}

.project-lightbox::backdrop {
  background: rgba(3, 7, 14, 0.88);
  backdrop-filter: blur(0.25rem);
}

.lightbox-shell {
  position: relative;
  display: grid;
  min-height: min(82vh, 48rem);
  place-items: center;
  padding: clamp(3.75rem, 7vw, 5rem) clamp(3.25rem, 8vw, 6rem) 1.25rem;
}

.lightbox-figure {
  display: grid;
  max-width: 100%;
  max-height: 72vh;
  justify-items: center;
  gap: 0.75rem;
}

.lightbox-figure img {
  max-width: 100%;
  max-height: 65vh;
  object-fit: contain;
}

.lightbox-figure figcaption {
  color: #d5e5ef;
  font-size: 0.95rem;
  text-align: center;
}

.lightbox-close,
.lightbox-nav {
  position: absolute;
  display: inline-grid;
  width: 2.8rem;
  height: 2.8rem;
  place-items: center;
  border: 1px solid rgba(var(--accent-primary-rgb), 0.35);
  border-radius: 50%;
  background: rgba(8, 16, 30, 0.9);
  color: var(--text-primary);
  cursor: pointer;
  font-family: var(--font-sans);
  transition: var(--transition-fast);
}

.lightbox-close:hover,
.lightbox-nav:hover {
  border-color: var(--accent-primary);
  color: var(--accent-primary);
}

.lightbox-close { top: 1rem; right: 1rem; font-size: 1.8rem; line-height: 1; }
.lightbox-nav { top: 50%; transform: translateY(-50%); font-size: 2rem; }
.lightbox-nav--previous { left: 1rem; }
.lightbox-nav--next { right: 1rem; }

body.lightbox-open { overflow: hidden; }

#competenze,
#settori,
#processo,
#project-antenna,
#project-fem,
#project-automation,
#project-structures,
#project-software { scroll-margin-top: 6.5rem; }

@media (max-width: 1100px) {
  .pillars-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pillars-grid--home .pillar-card { min-height: 17rem; }
  .process-timeline { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1.25rem; }
  .portfolio-card { grid-template-columns: 1fr; }
  .portfolio-card-gallery { min-height: 13rem; }
  .portfolio-card--software { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
  .section-space { padding-block: 4.25rem; }
  .section-anchor-nav { margin-top: 1.35rem; }
  .pillar-card { min-height: 16.5rem; }
  .pillar-card h3 { margin-top: 1.35rem; }
  .sector-grid,
  .portfolio-feature,
  .portfolio-grid,
  .portfolio-card--software { grid-template-columns: 1fr; }
  .portfolio-feature { padding: 1rem; }
  .portfolio-feature-copy { padding: 0.5rem; }
  .portfolio-card { min-height: 0; }
  .portfolio-card-gallery { min-height: 14rem; }
  .portfolio-card-gallery--two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .process-timeline { grid-template-columns: 1fr; gap: 0; }
  .process-timeline li { padding: 1.35rem 0 1.35rem 1.35rem; border-top: 0; border-left: 1px solid rgba(var(--accent-primary-rgb), 0.38); }
  .process-timeline li::before { top: 1.4rem; left: -0.28rem; }
  .integration-callout { align-items: flex-start; flex-direction: column; }
  .integration-callout .btn { width: 100%; }
  .lightbox-shell { min-height: 76vh; padding-inline: 3.25rem; }
}

@media (max-width: 480px) {
  .pillars-grid { grid-template-columns: 1fr; }
  .section-kicker { font-size: 0.67rem; letter-spacing: 0.1em; }
  .section-anchor-nav { gap: 0.45rem; }
  .section-anchor-nav a { padding: 0.4rem 0.65rem; font-size: 0.82rem; }
  .portfolio-thumbs { gap: 0.45rem; }
  .portfolio-card-gallery--two { gap: 0.5rem; }
  .portfolio-card-gallery { min-height: 12rem; }
  .lightbox-shell { min-height: 66vh; padding: 3.8rem 0.75rem 0.85rem; }
  .lightbox-nav { width: 2.3rem; height: 2.3rem; }
  .lightbox-nav--previous { left: 0.35rem; }
  .lightbox-nav--next { right: 0.35rem; }
  .lightbox-close { top: 0.55rem; right: 0.55rem; }
}

@media (prefers-reduced-motion: reduce) {
  .gallery-trigger img,
  .pillar-card,
  .section-anchor-nav a,
  .lightbox-close,
  .lightbox-nav { transition: none; }
  .gallery-trigger:hover img,
  .pillar-card:hover { transform: none; }
}

/* Portfolio: automation and software capability showcases */
.portfolio-card--showcase {
  grid-column: 1 / -1;
  grid-template-columns: minmax(17rem, 0.72fr) minmax(0, 1.28fr);
  min-height: 27rem;
}

.portfolio-card--showcase .portfolio-card-copy {
  padding: clamp(0.35rem, 1.25vw, 1rem);
}

.portfolio-card--automation {
  background:
    radial-gradient(circle at 78% 22%, rgba(var(--accent-primary-rgb), 0.1), transparent 24rem),
    linear-gradient(145deg, rgba(21, 32, 53, 0.98), rgba(10, 18, 31, 0.94));
}

.automation-showcase {
  display: grid;
  min-width: 0;
  grid-template-columns: minmax(0, 1.15fr) minmax(15rem, 0.85fr);
  gap: 0.85rem;
}

.automation-gallery-trigger {
  min-height: 100%;
  aspect-ratio: auto;
}

.automation-gallery-trigger img {
  object-position: center;
}

.automation-control-visual,
.software-showcase {
  border: 1px solid rgba(var(--accent-primary-rgb), 0.26);
  border-radius: 0.75rem;
  background:
    linear-gradient(rgba(0, 240, 255, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 240, 255, 0.045) 1px, transparent 1px),
    linear-gradient(145deg, #0d1a2c, #080f1c);
  background-size: 1.5rem 1.5rem, 1.5rem 1.5rem, auto;
  overflow: hidden;
}

.automation-control-visual {
  display: grid;
  min-height: 100%;
  grid-template-rows: auto 1fr;
  gap: 1rem;
  padding: 1rem;
}

.automation-flow {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  align-items: center;
  gap: 0.6rem;
}

.automation-node {
  position: relative;
  display: grid;
  min-height: 4.5rem;
  place-items: center;
  padding: 0.55rem 0.4rem;
  border: 1px solid rgba(var(--accent-primary-rgb), 0.28);
  border-radius: 0.6rem;
  background: rgba(4, 13, 25, 0.58);
  color: #dffcff;
  font-size: clamp(0.64rem, 0.78vw, 0.78rem);
  font-weight: 700;
  line-height: 1.2;
  text-align: center;
}

.automation-node::before {
  position: absolute;
  top: 0.48rem;
  left: 0.48rem;
  width: 0.34rem;
  height: 0.34rem;
  border-radius: 50%;
  background: var(--accent-primary);
  box-shadow: 0 0 0.75rem rgba(var(--accent-primary-rgb), 0.85);
  content: "";
  animation: capability-pulse 2.7s ease-in-out infinite;
}

.automation-node:nth-child(2)::before { animation-delay: 0.45s; }
.automation-node:nth-child(3)::before { animation-delay: 0.9s; }
.automation-node:nth-child(4)::before { animation-delay: 1.35s; }

.automation-node:not(:last-child)::after {
  position: absolute;
  z-index: 2;
  top: 50%;
  right: -0.78rem;
  color: var(--accent-primary);
  content: "→";
  font-size: 1rem;
  font-weight: 400;
  text-shadow: 0 0 0.7rem rgba(var(--accent-primary-rgb), 0.9);
  transform: translateY(-50%);
}

.pseudo-code-panel,
.software-api-panel {
  display: grid;
  gap: 0.55rem;
  padding: 0.8rem;
  border: 1px solid rgba(var(--accent-primary-rgb), 0.2);
  border-radius: 0.62rem;
  background: rgba(4, 10, 20, 0.72);
}

.pseudo-code-title {
  color: #9ec8dd;
  font-size: 0.69rem;
  font-weight: 800;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.pseudo-code-panel code,
.software-api-panel code {
  display: grid;
  gap: 0.3rem;
  color: #bceff6;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: clamp(0.68rem, 0.85vw, 0.78rem);
  line-height: 1.45;
}

.pseudo-code-panel code span::before,
.software-api-panel code span::before {
  margin-right: 0.4rem;
  color: var(--accent-primary);
  content: "›";
}

.pseudo-code-panel code span:last-child,
.software-api-panel code span:nth-child(2) {
  color: #74f5be;
}

.software-showcase {
  display: grid;
  min-height: 23rem;
  grid-template-columns: minmax(0, 1fr) minmax(6.7rem, 0.32fr);
  grid-template-rows: minmax(10rem, 1fr) auto;
  gap: 0.8rem;
  padding: 0.8rem;
}

.software-window {
  display: grid;
  min-width: 0;
  grid-row: 1 / -1;
  grid-template-rows: auto 1fr;
  border: 1px solid rgba(var(--accent-primary-rgb), 0.27);
  border-radius: 0.62rem;
  background: rgba(7, 17, 30, 0.8);
  overflow: hidden;
}

.software-window-bar {
  display: flex;
  align-items: center;
  gap: 0.32rem;
  min-height: 2.05rem;
  padding-inline: 0.65rem;
  border-bottom: 1px solid rgba(var(--accent-primary-rgb), 0.14);
  background: rgba(23, 42, 64, 0.52);
}

.software-window-bar > span {
  width: 0.42rem;
  height: 0.42rem;
  border-radius: 50%;
  background: rgba(140, 213, 227, 0.5);
}

.software-window-bar > span:first-child { background: #59edbd; }

.software-window-bar b {
  margin-left: 0.35rem;
  color: #d8f8fb;
  font-size: 0.69rem;
  font-weight: 700;
}

.software-workspace {
  display: grid;
  min-height: 0;
  grid-template-columns: 2.4rem minmax(0, 1fr);
}

.software-sidebar {
  display: grid;
  align-content: start;
  gap: 0.75rem;
  padding: 0.85rem 0.65rem;
  border-right: 1px solid rgba(var(--accent-primary-rgb), 0.12);
  background: rgba(1, 9, 18, 0.44);
}

.software-sidebar i {
  display: block;
  width: 100%;
  aspect-ratio: 1;
  border: 1px solid rgba(var(--accent-primary-rgb), 0.36);
  border-radius: 0.25rem;
  background: rgba(var(--accent-primary-rgb), 0.11);
}

.software-main {
  display: grid;
  min-width: 0;
  grid-template-rows: auto minmax(6rem, 1fr) auto;
  gap: 0.65rem;
  padding: 0.75rem;
}

.software-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.45rem;
}

.software-metrics span {
  min-height: 2rem;
  border: 1px solid rgba(var(--accent-primary-rgb), 0.18);
  border-radius: 0.35rem;
  background: linear-gradient(145deg, rgba(var(--accent-primary-rgb), 0.2), rgba(62, 99, 224, 0.08));
}

.software-map {
  position: relative;
  display: grid;
  min-height: 0;
  place-items: center;
  border: 1px solid rgba(var(--accent-primary-rgb), 0.18);
  border-radius: 0.45rem;
  background:
    linear-gradient(45deg, transparent 49%, rgba(var(--accent-primary-rgb), 0.12) 50%, transparent 51%),
    linear-gradient(-35deg, transparent 49%, rgba(var(--accent-primary-rgb), 0.1) 50%, transparent 51%),
    #0a1728;
  overflow: hidden;
}

.software-map b {
  z-index: 1;
  color: #e2fbff;
  font-size: 0.66rem;
  font-weight: 700;
}

.software-map i {
  position: absolute;
  width: 0.5rem;
  height: 0.5rem;
  border: 2px solid var(--accent-primary);
  border-radius: 50%;
  background: #0d1b2d;
  box-shadow: 0 0 0.75rem rgba(var(--accent-primary-rgb), 0.72);
  animation: capability-pulse 2.5s ease-in-out infinite;
}

.software-map i:nth-of-type(1) { top: 28%; left: 29%; }
.software-map i:nth-of-type(2) { top: 61%; right: 23%; animation-delay: 0.55s; }
.software-map i:nth-of-type(3) { bottom: 19%; left: 48%; animation-delay: 1.1s; }

.software-data-lines {
  display: grid;
  gap: 0.36rem;
}

.software-data-lines i {
  display: block;
  height: 0.35rem;
  border-radius: 999px;
  background: rgba(188, 239, 246, 0.35);
}

.software-data-lines i:nth-child(2) { width: 74%; }
.software-data-lines i:nth-child(3) { width: 48%; }

.software-device {
  display: grid;
  min-height: 0;
  place-content: start center;
  gap: 0.8rem;
  padding: 1rem 0.55rem;
  border: 1px solid rgba(var(--accent-primary-rgb), 0.25);
  border-radius: 0.75rem;
  background: linear-gradient(170deg, #112941, #09111f);
}

.software-device::before {
  width: 2.6rem;
  height: 0.28rem;
  border-radius: 999px;
  background: rgba(198, 247, 255, 0.45);
  content: "";
}

.software-device span {
  color: #e1fbff;
  font-size: 0.68rem;
  font-weight: 800;
  text-align: center;
}

.software-device i {
  display: block;
  width: 100%;
  height: 0.5rem;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--accent-primary), #3879e7);
}

.software-device i:nth-of-type(2) { width: 70%; }
.software-device i:nth-of-type(3) { width: 48%; }

.software-api-panel {
  align-self: end;
}

@keyframes capability-pulse {
  0%, 100% { opacity: 0.62; transform: scale(0.9); }
  50% { opacity: 1; transform: scale(1.14); }
}

@media (max-width: 1100px) {
  .portfolio-card--showcase {
    grid-template-columns: 1fr;
    min-height: 0;
  }

  .automation-showcase {
    min-height: 21rem;
  }

  .portfolio-card--showcase .portfolio-card-copy {
    padding: 0.25rem;
  }
}

@media (max-width: 768px) {
  .automation-showcase {
    grid-template-columns: 1fr;
    min-height: 0;
  }

  .automation-gallery-trigger {
    min-height: 14rem;
  }

  .automation-control-visual {
    min-height: 14rem;
  }

  .software-showcase {
    min-height: 20rem;
  }
}

@media (max-width: 480px) {
  .automation-flow {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.6rem 1rem;
  }

  .automation-node { min-height: 3.85rem; }
  .automation-node::before { top: 0.35rem; left: 0.35rem; }
  .automation-node::after { display: none; }

  .software-showcase {
    min-height: 18rem;
    grid-template-columns: minmax(0, 1fr) 5.7rem;
    gap: 0.55rem;
    padding: 0.55rem;
  }

  .software-workspace { grid-template-columns: 1.9rem minmax(0, 1fr); }
  .software-sidebar { gap: 0.5rem; padding-inline: 0.45rem; }
  .software-main { gap: 0.45rem; padding: 0.55rem; }
  .software-window-bar b { font-size: 0.61rem; }
  .software-device { gap: 0.55rem; padding-inline: 0.4rem; }
  .software-api-panel { padding: 0.55rem; }
  .software-api-panel code { font-size: 0.6rem; }
}

@media (prefers-reduced-motion: reduce) {
  .automation-node::before,
  .software-map i { animation: none; }
}

@media (max-width: 420px) {
  .container {
    padding: 0 1rem;
  }

  .main-logo {
    height: 52px;
    width: 52px;
  }

  .header-controls {
    gap: 1rem;
  }

  .lang-toggle-btn {
    padding: 0.35rem 0.65rem;
  }

  .hero-section h1 {
    font-size: 2rem;
  }

  .btn {
    padding: 0.75rem 1.2rem;
  }
}

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

  .js .scroll-reveal {
    opacity: 1;
    transform: none;
  }
}

/* Page Banner */
.page-banner {
  background: linear-gradient(
    180deg,
    var(--bg-secondary) 0%,
    var(--bg-primary) 100%
  );
  padding-top: 150px;
  padding-bottom: 2.5rem;
  border-bottom: 1px solid var(--glass-border);
  text-align: center;
}

.page-banner h1 {
  font-size: 3rem;
  margin-bottom: 0.5rem;
}

.page-banner .section-underline {
  margin-bottom: 1rem;
}

/* Subpage Utilities to replace inline styles */
.about-section-subpage {
  padding-top: 4.5rem;
}

.about-section-subpage .about-text-content h2 {
  font-size: 2rem;
  margin-bottom: 1.5rem;
}

.about-section-subpage .about-text-content h3 {
  font-size: 1.4rem;
  margin-top: 2.5rem;
  margin-bottom: 1rem;
}

.about-section-subpage .about-visual-container {
  align-self: start;
  margin-top: 2rem;
}

.about-ctas-home {
  margin-top: 2rem;
}

.services-section-subpage {
  padding-bottom: 4rem;
  padding-top: 5rem;
}

.details-section-subpage {
  padding-top: 2rem;
}

.cta-section-subpage {
  background: linear-gradient(180deg, var(--bg-primary), var(--bg-secondary));
  padding: 6rem 0;
  text-align: center;
  border-top: 1px solid var(--glass-border);
}

.cta-section-subpage .container {
  max-width: 700px;
}

.cta-section-subpage h2 {
  font-size: 2.2rem;
  margin-bottom: 1.2rem;
}

.cta-section-subpage p {
  font-size: 1.1rem;
  margin-bottom: 2.5rem;
}

/* Utilities */
.text-center {
  text-align: center;
}
.mt-4 {
  margin-top: 4rem;
}

.detail-value {
  text-decoration: none;
}

a.detail-value:hover {
  color: var(--accent-primary);
}

@media (max-width: 768px) {
  .page-banner {
    padding-top: 115px;
    padding-bottom: 2.25rem;
  }

  .page-banner h1 {
    font-size: 2.25rem;
  }

  .about-section-subpage,
  .services-section-subpage {
    padding-top: 4rem;
  }

  .details-section-subpage {
    padding-top: 1rem;
  }

  .cta-section-subpage {
    padding: 4rem 0;
  }

  .cta-section-subpage h2 {
    font-size: 1.8rem;
  }
}

/* --------------------------------------------------------------------------
   2026 visual refresh
   A precise, quieter engineering system shared by every page and theme.
   -------------------------------------------------------------------------- */

body {
  background:
    linear-gradient(var(--grid-line) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px),
    var(--bg-primary);
  background-size: 72px 72px;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(circle at 12% 8%, rgba(var(--accent-secondary-rgb), 0.12), transparent 28rem),
    radial-gradient(circle at 88% 26%, rgba(var(--accent-primary-rgb), 0.09), transparent 30rem);
}

.skip-link {
  position: fixed;
  top: 0.75rem;
  left: 0.75rem;
  z-index: 1000;
  padding: 0.75rem 1rem;
  border-radius: 0.65rem;
  color: var(--button-ink);
  background: var(--accent-primary);
  font-weight: 700;
  text-decoration: none;
  transform: translateY(-150%);
  transition: transform 0.2s ease;
}

.skip-link:focus {
  transform: translateY(0);
}

.container {
  max-width: 1240px;
}

.btn {
  min-height: 48px;
  padding-inline: 1.4rem;
  border-radius: 0.75rem;
  letter-spacing: 0.01em;
}

.btn-primary {
  color: var(--button-ink);
  background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
  box-shadow: 0 12px 32px rgba(var(--accent-secondary-rgb), 0.2);
}

.btn-outline {
  background: rgba(var(--accent-primary-rgb), 0.035);
  border-color: var(--glass-border);
}

.glass-panel,
.glass-card {
  border-radius: 1.1rem;
  box-shadow: var(--shadow-glow);
}

.glass-card {
  isolation: isolate;
}

#main-header {
  padding-block: 0.7rem;
}

#main-header .nav-container {
  min-height: 68px;
  padding-block: 0.35rem;
}

.header-scrolled,
html[data-theme="light"] .header-scrolled {
  padding-block: 0.35rem;
  background: var(--header-bg);
  border-color: var(--glass-border);
  box-shadow: 0 12px 40px rgba(0, 13, 31, 0.12);
}

.main-logo {
  width: 58px;
  height: 58px;
}

.header-scrolled .main-logo {
  width: 50px;
  height: 50px;
}

.desktop-nav ul {
  gap: 0.4rem;
  padding: 0.35rem;
  border: 1px solid var(--glass-border);
  border-radius: 999px;
  background: rgba(var(--accent-primary-rgb), 0.025);
}

.desktop-nav a {
  display: block;
  padding: 0.55rem 0.9rem;
  border-radius: 999px;
  font-weight: 600;
}

.desktop-nav a::after {
  display: none;
}

.desktop-nav a:hover,
.desktop-nav a.active {
  color: var(--text-primary);
  background: rgba(var(--accent-primary-rgb), 0.1);
}

.header-controls {
  gap: 0.65rem;
}

.lang-toggle-btn,
.theme-toggle-btn {
  min-height: 42px;
  border: 1px solid var(--glass-border);
  background: rgba(var(--accent-primary-rgb), 0.055);
  color: var(--text-primary);
}

.lang-toggle-btn {
  padding-inline: 0.85rem;
}

.theme-toggle-btn {
  display: grid;
  width: 42px;
  place-items: center;
  border-radius: 50%;
  cursor: pointer;
  transition: var(--transition-fast);
}

.theme-toggle-btn:hover,
.lang-toggle-btn:hover {
  border-color: var(--glass-border-hover);
  background: rgba(var(--accent-primary-rgb), 0.11);
  transform: translateY(-1px);
}

.theme-toggle-icon {
  font-size: 1.05rem;
  line-height: 1;
}

.hero-section {
  min-height: min(900px, 100svh);
  justify-content: flex-start;
  padding: 10rem 0 7rem;
  border-bottom: 1px solid var(--glass-border);
}

.hero-section::before {
  content: "";
  position: absolute;
  inset: 10% -10% auto 48%;
  height: 72%;
  border: 1px solid rgba(var(--accent-primary-rgb), 0.12);
  border-radius: 50%;
  background: radial-gradient(circle, rgba(var(--accent-primary-rgb), 0.11), transparent 63%);
  filter: blur(0.2px);
}

.hero-bg-visual {
  left: auto;
  right: max(-8rem, calc((100vw - 1440px) / 2));
  width: min(62vw, 820px);
  height: min(72vw, 820px);
  opacity: 0.21;
  transform: translateY(-50%);
}

.hero-content {
  align-items: flex-start;
  max-width: 790px;
  margin-inline: 0;
  text-align: left;
}

.hero-tagline {
  margin-bottom: 1.6rem;
  padding: 0.45rem 1rem 0.45rem 1.35rem;
  background: rgba(var(--accent-primary-rgb), 0.07);
  border-color: rgba(var(--accent-primary-rgb), 0.23);
}

.hero-section h1 {
  max-width: 760px;
  margin-bottom: 1.45rem;
  font-size: clamp(3.3rem, 7vw, 6.7rem);
  line-height: 0.98;
  letter-spacing: -0.045em;
}

.hero-section p {
  max-width: 680px;
  margin-bottom: 2.1rem;
  font-size: clamp(1.08rem, 1.5vw, 1.28rem);
  line-height: 1.7;
}

.hero-ctas {
  gap: 0.8rem;
}

.hero-disciplines {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  width: min(100%, 730px);
  margin-top: 3.5rem;
  list-style: none;
  border-block: 1px solid var(--glass-border);
}

.hero-disciplines li {
  display: grid;
  gap: 0.35rem;
  min-height: 96px;
  padding: 1.15rem 1.25rem;
  border-right: 1px solid var(--glass-border);
}

.hero-disciplines li:first-child {
  padding-left: 0;
}

.hero-disciplines li:last-child {
  border-right: 0;
}

.hero-disciplines span {
  color: var(--accent-primary);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.75rem;
}

.hero-disciplines strong {
  max-width: 13rem;
  color: var(--text-primary);
  font-size: 0.95rem;
  line-height: 1.35;
}

.scroll-down-indicator {
  left: auto;
  right: clamp(1.25rem, 4vw, 3.5rem);
  transform: none;
}

section {
  padding-block: clamp(5rem, 8vw, 8rem);
}

.section-heading,
.section-header {
  text-align: left;
}

.section-heading {
  max-width: 780px;
  margin-inline: 0;
}

.section-header {
  display: grid;
  justify-items: start;
}

.section-underline {
  width: 84px;
  height: 3px;
  margin-inline: 0;
}

.section-title,
.section-heading h2,
.page-banner h1 {
  font-size: clamp(2.35rem, 5vw, 4.5rem);
  line-height: 1.02;
  letter-spacing: -0.035em;
}

.about-section,
.sectors-section,
.process-section,
.contact-section {
  background: linear-gradient(180deg, transparent, var(--section-tint), transparent);
}

.about-grid {
  gap: clamp(3rem, 7vw, 7.5rem);
}

.about-text-content h3,
.about-section-subpage .about-text-content h2 {
  font-size: clamp(1.8rem, 3vw, 3rem);
  line-height: 1.12;
  letter-spacing: -0.025em;
}

.about-text-content p {
  max-width: 68ch;
  font-size: 1.05rem;
}

.about-card {
  min-height: 360px;
  justify-content: flex-end;
  text-align: left;
  padding: clamp(2rem, 5vw, 3.4rem);
  background:
    radial-gradient(circle at 25% 20%, rgba(var(--accent-primary-rgb), 0.15), transparent 40%),
    var(--glass-bg);
}

.logo-fallback-wrapper {
  margin-inline: 0;
}

.pillars-grid,
.sector-grid,
.portfolio-grid {
  gap: 1rem;
}

.pillar-card,
.sector-card,
.portfolio-card {
  border-top: 2px solid rgba(var(--accent-primary-rgb), 0.28);
}

.pillar-card {
  min-height: 300px;
  padding: 2rem;
}

.pillar-number,
.project-index,
.sector-index {
  color: var(--accent-primary);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  letter-spacing: 0.1em;
}

.pillar-card h3 {
  margin-top: auto;
  font-size: 1.35rem;
}

.page-banner,
.portfolio-banner {
  min-height: 430px;
  display: flex;
  align-items: flex-end;
  padding: 10rem 0 4rem;
  text-align: left;
  background:
    radial-gradient(circle at 78% 20%, rgba(var(--accent-primary-rgb), 0.14), transparent 28rem),
    linear-gradient(180deg, var(--bg-secondary), var(--bg-primary));
}

.page-banner .section-underline {
  margin-inline: 0;
}

.section-anchor-nav {
  justify-content: flex-start;
  gap: 0.5rem;
}

.section-anchor-nav a {
  border: 1px solid var(--glass-border);
  border-radius: 999px;
  background: rgba(var(--accent-primary-rgb), 0.035);
}

.process-timeline::before {
  background: linear-gradient(var(--accent-primary), var(--accent-secondary));
}

.gallery-trigger {
  border-radius: 0.9rem;
}

.gallery-trigger:focus-visible {
  outline: 3px solid rgba(var(--accent-primary-rgb), 0.75);
  outline-offset: 4px;
}

.contact-action-card {
  padding: clamp(2rem, 5vw, 3.5rem);
  background:
    radial-gradient(circle at 95% 0%, rgba(var(--accent-secondary-rgb), 0.15), transparent 17rem),
    var(--glass-bg);
}

footer {
  padding-block: 2rem;
  background: rgba(3, 11, 21, 0.66);
  border-top: 1px solid var(--glass-border);
}

html[data-theme="light"] footer {
  background: rgba(255, 255, 255, 0.55);
}

.footer-content {
  min-height: 82px;
}

.footer-brand span {
  font-weight: 800;
}

@media (max-width: 980px) {
  .desktop-nav ul {
    gap: 0;
  }

  .desktop-nav a {
    padding-inline: 0.65rem;
    font-size: 0.86rem;
  }

  .hero-section::before {
    left: 38%;
  }

  .hero-bg-visual {
    right: -16rem;
  }
}

@media (max-width: 768px) {
  body {
    background-size: 48px 48px;
  }

  #main-header .nav-container {
    min-height: 58px;
  }

  .header-transparent,
  .header-scrolled,
  html[data-theme="light"] .header-transparent,
  html[data-theme="light"] .header-scrolled {
    background: var(--header-bg);
  }

  .main-logo,
  .header-scrolled .main-logo {
    width: 48px;
    height: 48px;
  }

  .lang-toggle-btn,
  .theme-toggle-btn {
    min-height: 40px;
  }

  .theme-toggle-btn {
    width: 40px;
  }

  .mobile-nav-toggle {
    width: 28px;
    height: 20px;
    margin-left: 0.25rem;
  }

  .mobile-nav-drawer {
    background: var(--header-bg);
  }

  .hero-section {
    min-height: auto;
    padding: 9rem 0 5rem;
  }

  .hero-section::before {
    inset: 16% -48% auto 24%;
    height: 52%;
  }

  .hero-bg-visual {
    top: 32%;
    right: -50%;
    width: 115vw;
    height: 115vw;
    opacity: 0.13;
  }

  .hero-section h1 {
    font-size: clamp(2.8rem, 14vw, 4.4rem);
  }

  .hero-ctas {
    flex-direction: row;
  }

  .hero-ctas .btn {
    width: auto;
    flex: 1;
  }

  .hero-disciplines {
    grid-template-columns: 1fr;
    margin-top: 2.75rem;
  }

  .hero-disciplines li {
    grid-template-columns: 2.2rem 1fr;
    align-items: center;
    min-height: 62px;
    padding: 0.8rem 0;
    border-right: 0;
    border-bottom: 1px solid var(--glass-border);
  }

  .hero-disciplines li:last-child {
    border-bottom: 0;
  }

  .section-heading,
  .section-header {
    max-width: 100%;
  }

  .page-banner,
  .portfolio-banner {
    min-height: 330px;
    padding: 8rem 0 3rem;
  }

  .about-card {
    min-height: 300px;
  }
}

@media (max-width: 460px) {
  .header-controls {
    gap: 0.4rem;
  }

  .lang-toggle-btn {
    padding-inline: 0.65rem;
  }

  .hero-ctas {
    flex-direction: column;
  }

  .hero-ctas .btn {
    width: 100%;
  }

  .hero-tagline span {
    font-size: 0.64rem;
  }
}

/* Light-theme component audit
   Keep every authored surface theme-aware, including the technical mockups. */
html[data-theme="light"] .collaborations-section {
  background: linear-gradient(180deg, var(--bg-primary), rgba(255, 255, 255, 0.72));
}

html[data-theme="light"] .collaboration-item {
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 16px 42px rgba(35, 72, 111, 0.09);
}

html[data-theme="light"] .collaboration-item:hover {
  background: #ffffff;
  box-shadow: 0 20px 48px rgba(35, 72, 111, 0.14);
}

html[data-theme="light"] .home-capabilities-section {
  background: linear-gradient(180deg, var(--bg-primary), #f8fbff 62%, var(--bg-primary));
}

html[data-theme="light"] .pillar-card {
  background: linear-gradient(155deg, rgba(255, 255, 255, 0.98), rgba(235, 244, 253, 0.94));
  box-shadow: 0 18px 48px rgba(35, 72, 111, 0.1);
}

html[data-theme="light"] .sectors-section {
  background: linear-gradient(120deg, rgba(255, 255, 255, 0.86), rgba(226, 238, 250, 0.62));
}

html[data-theme="light"] .sector-card ul,
html[data-theme="light"] .capability-tags li,
html[data-theme="light"] .project-tags li {
  color: var(--text-secondary);
}

html[data-theme="light"] .sketch-container,
html[data-theme="light"] .form-group input,
html[data-theme="light"] .form-group textarea {
  background: rgba(255, 255, 255, 0.82);
  box-shadow: inset 0 0 20px rgba(35, 72, 111, 0.06);
}

html[data-theme="light"] .form-group input:focus,
html[data-theme="light"] .form-group textarea:focus {
  background: #ffffff;
}

html[data-theme="light"] .code-terminal {
  background: #f7faff;
  border-color: rgba(var(--accent-primary-rgb), 0.2);
}

html[data-theme="light"] .terminal-header {
  background: #e5eef8;
  border-bottom-color: rgba(18, 52, 85, 0.1);
}

html[data-theme="light"] .specs-list li {
  border-bottom-color: rgba(18, 52, 85, 0.1);
}

html[data-theme="light"] .portfolio-card--automation {
  background:
    radial-gradient(circle at 78% 22%, rgba(var(--accent-primary-rgb), 0.1), transparent 24rem),
    linear-gradient(145deg, rgba(255, 255, 255, 0.98), rgba(229, 240, 251, 0.94));
}

html[data-theme="light"] .automation-control-visual,
html[data-theme="light"] .software-showcase,
html[data-theme="light"] .software-surface {
  background:
    linear-gradient(rgba(var(--accent-primary-rgb), 0.065) 1px, transparent 1px),
    linear-gradient(90deg, rgba(var(--accent-primary-rgb), 0.065) 1px, transparent 1px),
    linear-gradient(145deg, #f8fbff, #e5eff9);
  background-size: 1.5rem 1.5rem, 1.5rem 1.5rem, auto;
}

html[data-theme="light"] .automation-node {
  background: rgba(255, 255, 255, 0.84);
  color: var(--text-primary);
  box-shadow: 0 8px 20px rgba(35, 72, 111, 0.07);
}

html[data-theme="light"] .pseudo-code-panel,
html[data-theme="light"] .software-api-panel {
  background: rgba(255, 255, 255, 0.8);
}

html[data-theme="light"] .pseudo-code-title,
html[data-theme="light"] .pseudo-code-panel code,
html[data-theme="light"] .software-api-panel code,
html[data-theme="light"] .software-window-bar b,
html[data-theme="light"] .software-map b,
html[data-theme="light"] .software-device span {
  color: var(--text-primary);
}

html[data-theme="light"] .pseudo-code-panel code span:last-child,
html[data-theme="light"] .software-api-panel code span:nth-child(2) {
  color: #087c5b;
}

html[data-theme="light"] .software-window {
  background: rgba(255, 255, 255, 0.82);
}

html[data-theme="light"] .software-window-bar {
  background: #dce9f6;
  border-bottom-color: rgba(18, 52, 85, 0.1);
}

html[data-theme="light"] .software-window-bar > span {
  background: rgba(0, 95, 135, 0.35);
}

html[data-theme="light"] .software-sidebar {
  background: rgba(221, 234, 247, 0.74);
  border-right-color: rgba(18, 52, 85, 0.1);
}

html[data-theme="light"] .software-map {
  background:
    linear-gradient(45deg, transparent 49%, rgba(var(--accent-primary-rgb), 0.1) 50%, transparent 51%),
    linear-gradient(-35deg, transparent 49%, rgba(var(--accent-primary-rgb), 0.08) 50%, transparent 51%),
    #edf5fc;
}

html[data-theme="light"] .software-map i {
  background: #ffffff;
}

html[data-theme="light"] .software-device {
  background: linear-gradient(170deg, #eef6fd, #dce9f6);
}

html[data-theme="light"] .software-device::before,
html[data-theme="light"] .software-data-lines i,
html[data-theme="light"] .software-line {
  background: rgba(0, 95, 135, 0.28);
}

html[data-theme="light"] .gallery-trigger {
  background: #e5eef8;
}

html[data-theme="light"] .project-lightbox {
  background: #f7faff;
  box-shadow: 0 1.25rem 5rem rgba(24, 57, 91, 0.24);
}

html[data-theme="light"] .project-lightbox::backdrop {
  background: rgba(20, 39, 62, 0.58);
}

html[data-theme="light"] .lightbox-figure figcaption {
  color: var(--text-secondary);
}

html[data-theme="light"] .lightbox-close,
html[data-theme="light"] .lightbox-nav {
  background: rgba(255, 255, 255, 0.94);
}

/* Expanded company footer */
.site-footer {
  padding: clamp(4.5rem, 8vw, 7rem) 0 0;
  background: radial-gradient(circle at 12% 0%, rgba(var(--accent-primary-rgb), 0.08), transparent 24rem), #050a11;
  border-top: 1px solid rgba(164, 208, 255, 0.1);
}
.footer-grid { display: grid; grid-template-columns: 1.25fr 1fr .8fr 1.05fr; gap: clamp(2.25rem, 5vw, 5.5rem); padding-bottom: clamp(3.5rem, 7vw, 6rem); }
.footer-brand-column, .footer-column { min-width: 0; }
.site-footer .footer-brand { display: inline-flex; align-items: center; gap: .85rem; color: #f8fafc; font-size: clamp(1.3rem, 2vw, 1.65rem); font-weight: 700; line-height: 1; text-decoration: none; }
.site-footer .footer-logo { width: 38px; height: 38px; }
.footer-tagline { margin-top: 1.75rem; color: #74869d; font-size: 1rem; line-height: 1.75; }
.footer-column h2 { margin-bottom: 1.55rem; color: #f8fafc; font-size: 1.1rem; }
.footer-column address, .footer-column nav { display: flex; flex-direction: column; align-items: flex-start; gap: 1.05rem; font-style: normal; }
.footer-column p { color: #74869d; font-size: 1rem; line-height: 1.55; }
.footer-column p + nav { margin-top: .55rem; }
.footer-column a, .footer-link-button { color: #74869d; font: inherit; font-size: 1rem; line-height: 1.55; text-align: left; text-decoration: underline; text-decoration-color: rgba(116, 134, 157, .55); text-underline-offset: .2em; transition: var(--transition-fast); }
.footer-link-button { padding: 0; border: 0; background: transparent; cursor: pointer; }
.footer-column a:hover, .footer-column a:focus-visible, .footer-link-button:hover, .footer-link-button:focus-visible { color: #4dd9ff; text-decoration-color: currentColor; }
.footer-bottom { padding: 1.5rem 0 2rem; border-top: 1px solid rgba(164, 208, 255, .12); }
.footer-bottom p { color: #74869d; font-size: .875rem; }
html[data-theme="light"] .site-footer { background: radial-gradient(circle at 12% 0%, rgba(var(--accent-primary-rgb), .08), transparent 24rem), #f7faff; border-top-color: rgba(18, 52, 85, .12); }
html[data-theme="light"] .site-footer .footer-brand, html[data-theme="light"] .footer-column h2 { color: var(--text-primary); }
html[data-theme="light"] .footer-tagline, html[data-theme="light"] .footer-column p, html[data-theme="light"] .footer-column a, html[data-theme="light"] .footer-link-button, html[data-theme="light"] .footer-bottom p { color: var(--text-secondary); }
html[data-theme="light"] .footer-bottom { border-top-color: rgba(18, 52, 85, .12); }

.cookie-preferences-dialog { width: min(92vw, 600px); margin: auto; padding: 0; color: var(--text-primary); background: var(--bg-secondary); border: 1px solid var(--glass-border-hover); border-radius: 1.35rem; box-shadow: 0 2rem 6rem rgba(0,0,0,.42); }
.cookie-preferences-dialog::backdrop { background: rgba(1,7,14,.74); backdrop-filter: blur(8px); }
.cookie-preferences-dialog form { display: grid; gap: 1.4rem; padding: clamp(1.5rem,5vw,2.5rem); }
.cookie-preferences-dialog h2 { font-size: clamp(1.6rem,5vw,2.2rem); }
.cookie-preference-row { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 1rem 1.1rem; background: var(--glass-bg); border: 1px solid var(--glass-border); border-radius: .9rem; }
.cookie-preference-row div { display: grid; gap: .15rem; }
.cookie-preference-row div span { color: var(--text-secondary); }
.cookie-status { flex: 0 0 auto; color: var(--accent-primary); font-size: .85rem; font-weight: 700; }
html[data-theme="light"] .cookie-preferences-dialog { background: #fff; box-shadow: 0 2rem 6rem rgba(24,57,91,.24); }

.legal-main { min-height: 72vh; }
.legal-hero { padding: clamp(9rem,16vw,12rem) 0 3rem; }
.legal-hero .section-intro { max-width: 720px; }
.legal-content { padding: 1rem 0 clamp(5rem,9vw,8rem); }
.legal-card { max-width: 840px; padding: clamp(1.5rem,4vw,2.25rem); background: var(--glass-bg); border: 1px solid var(--glass-border); border-radius: 1.15rem; box-shadow: var(--shadow-glow); }
html[data-theme="light"] .legal-card { background: rgba(255,255,255,.86); }
@media (max-width: 900px) { .footer-grid { grid-template-columns: repeat(2,minmax(0,1fr)); } }
@media (max-width: 600px) { .site-footer { padding-top: 3.75rem; } .footer-grid { grid-template-columns: 1fr; gap: 2.75rem; } .cookie-preference-row { align-items: flex-start; flex-direction: column; } }

/* Contact strip above the primary navigation */
body { padding-top: 44px; }
#main-header { padding-top: 0; }
.contact-topbar { background: #123459; color: #f6f9ff; border-bottom: 1px solid #ffffff20; }
.contact-topbar-inner { min-height: 44px; display: flex; align-items: center; flex-wrap: wrap; gap: 8px 28px; padding-block: 8px; font-size: .875rem; line-height: 1.5; }
.contact-topbar a { color: #f6f9ff; display: inline-flex; align-items: center; gap: 9px; text-decoration: none; overflow-wrap: anywhere; }
.contact-topbar a span { color: #65d5ee; }
.contact-topbar a:hover { text-decoration: underline; text-underline-offset: 4px; }
.contact-topbar a:focus-visible { outline: 2px solid #65d5ee; outline-offset: 4px; }
.contact-topbar-location { margin-left: auto; color: #c7d8ec; }
@media (max-width: 600px) {
 body { padding-top: 72px; }
 .contact-topbar-inner { min-height: 72px; gap: 3px; align-items: flex-start; justify-content: center; flex-direction: column; }
 .contact-topbar-location { display: none; }
}

.contact-topbar-inner { gap: 8px 24px; }
.contact-topbar-hours { display: inline-flex; align-items: center; gap: 9px; }
.contact-topbar-hours > span:first-child { color: #65d5ee; }
.contact-topbar .lang-switch-wrapper { margin-left: auto; }
.contact-topbar .lang-toggle-btn { background: transparent; color: #fff; border-color: #ffffff40; min-height: 36px; font-size: .875rem; }
.contact-topbar .lang-divider { color: #c7d8ec; }
.contact-topbar .active-lang { color: #65d5ee; }
.contact-topbar .inactive-lang { opacity: .85; }
@media (min-width: 601px) and (max-width: 1100px) {
 body { padding-top: 96px; }
 .contact-topbar-inner { min-height: 96px; display: grid; grid-template-columns: 1fr auto; gap: 4px 16px; }
 .contact-topbar-hours { grid-column: 1; }
 .contact-topbar .lang-switch-wrapper { grid-column: 2; grid-row: 1 / 4; }
}
@media (max-width: 600px) {
 body { padding-top: 112px; }
 .contact-topbar-inner { min-height: 112px; position: relative; padding-right: 100px; gap: 4px; }
 .contact-topbar-hours { font-size: .875rem; flex-wrap: wrap; gap: 5px; }
 .contact-topbar .lang-switch-wrapper { position: absolute; right: 0; top: 12px; }
 .contact-topbar .lang-toggle-btn { min-height: 44px; padding: .4rem .65rem; }
}

@media (min-width: 1101px) { body { padding-top: 60px; } .contact-topbar-inner { min-height: 60px; } }
