/* ==========================================================================
   Enserv Company - Oilfield Engineering Technical Design System
   Brand Tokens:
   - Primary Navy:   #252E4B (Structure, backgrounds, authoritative technical base)
   - Brand Blue:     #51B0DE (Data, active links, technical line-art, focus states)
   - Mid Blue:       #3C6F96 (Secondary text / subtle borders on dark backgrounds)
   - Neutral Gray:   #7B7979 (Labels, captions, hairline technical dividers)
   - Accent Orange:  #F36717 (Reserved for EXACTLY ONE primary CTA per page)
   - Neutral Light:  #F5F7FA (Crisp technical background)
   - Neutral Dark:   #1A1F26 (Charcoal high-contrast technical body text)
   ========================================================================== */

:root {
  --color-primary-navy: #252E4B;
  --color-brand-blue: #51B0DE;
  --color-mid-blue: #3C6F96;
  --color-neutral-gray: #7B7979;
  --color-accent-orange: #F36717;
  --color-neutral-light: #F5F7FA;
  --color-neutral-dark: #1A1F26;

  /* Typography: Technical heritage with IBM Plex Sans & IBM Plex Mono */
  --font-sans: 'IBM Plex Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'IBM Plex Mono', 'SFMono-Regular', Consolas, Menlo, monospace;
  --font-heading: 'IBM Plex Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

  /* Aliases for components using --c- */
  --c-navy: #252E4B;
  --c-brand-blue: #51B0DE;
  --c-mid-blue: #3C6F96;
  --c-border: rgba(81, 176, 222, 0.25);

  /* Hairline borders */
  --border-light: 1px solid rgba(123, 121, 121, 0.25);
  --border-dark: 1px solid rgba(81, 176, 222, 0.2);
}

/* ==========================================================================
   Global Discipline: Industrial crisp geometry
   ========================================================================== */
*, *::before, *::after {
  box-sizing: border-box;
}

html, body, button, input, select, textarea, div, section, article {
  border-radius: 0;
}

html {
  font-family: var(--font-sans);
  scroll-behavior: smooth;
  color: var(--color-neutral-dark);
  background-color: #FFFFFF;
  font-size: 16px;
  line-height: 1.625;
}

body {
  font-family: var(--font-sans);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Constrain technical body reading width under ~75 characters */
.prose-technical p,
.tech-body {
  max-width: 72ch;
}

/* Numeric technical data styling */
.tech-data,
.font-mono {
  font-family: var(--font-mono);
  font-feature-settings: 'tnum' 1, 'zero' 1;
}

/* Section scroll margin offset for fixed header */
section[id],
footer[id],
main[id],
div[id] {
  scroll-margin-top: 76px;
}

/* ==========================================================================
   NAV SCROLL BEHAVIOR: Transparent over Hero to Solid Primary Navy
   ========================================================================== */
#site-header {
  background-color: transparent;
  border-bottom: 1px solid transparent;
  transition: background-color 0.3s cubic-bezier(0.16, 1, 0.3, 1), 
              backdrop-filter 0.3s ease, 
              border-color 0.3s ease, 
              padding 0.25s ease-out;
}

#site-header.header-scrolled,
#site-header.header-solid {
  background-color: rgba(26, 31, 38, 0.94) !important;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(81, 176, 222, 0.2) !important;
}

#site-header .nav-link {
  font-weight: 500;
  color: #E2E8F0;
  transition: color 0.15s ease;
  padding: 6px 0;
  position: relative;
}

#site-header .nav-link:hover {
  color: var(--color-brand-blue);
}

#site-header .nav-link.active-nav {
  color: var(--color-brand-blue) !important;
  font-weight: 600;
}

#site-header .nav-link.active-nav::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background-color: var(--color-brand-blue);
}

/* Nav Dropdowns (Desktop) */
.nav-dropdown-wrapper {
  position: relative;
}

.nav-dropdown-menu {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 260px;
  background: #1A1F26;
  border: 1px solid rgba(81, 176, 222, 0.25);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.5);
  padding: 8px 0;
  opacity: 0;
  pointer-events: none;
  transform: translateY(8px);
  transition: opacity 0.2s ease, transform 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  z-index: 60;
}

.nav-dropdown-wrapper:hover .nav-dropdown-menu,
.nav-dropdown-wrapper:focus-within .nav-dropdown-menu {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.nav-dropdown-item {
  display: block;
  padding: 8px 18px;
  font-size: 13px;
  color: #CBD5E1;
  transition: background-color 0.15s ease, color 0.15s ease;
  text-decoration: none;
}

.nav-dropdown-item:hover {
  background-color: rgba(81, 176, 222, 0.12);
  color: var(--color-brand-blue);
}

/* Focus outline for accessibility */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--color-brand-blue);
  outline-offset: 1px;
}

/* Mobile menu container */
#mobile-menu {
  transition: max-height 0.25s ease, opacity 0.2s ease, padding 0.25s ease;
  background-color: #1A1F26;
}

#mobile-menu.menu-closed {
  max-height: 0;
  opacity: 0;
  pointer-events: none;
  overflow: hidden;
  margin-top: 0 !important;
  padding-top: 0 !important;
  padding-bottom: 0 !important;
  border-top-color: transparent !important;
}

#mobile-menu.menu-open {
  max-height: 600px;
  opacity: 1;
  pointer-events: auto;
  overflow-y: auto;
}

/* ==========================================================================
   HERO: Static Industrial Authority & Technical HUD Dock
   ========================================================================== */
.hero-hud-dock {
  border-top: 1px solid rgba(81, 176, 222, 0.25);
  background: rgba(26, 31, 38, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.hero-hud-item {
  border-right: 1px solid rgba(81, 176, 222, 0.2);
  transition: background-color 0.2s ease, border-color 0.2s ease;
}

.hero-hud-item:last-child {
  border-right: none;
}

.hero-hud-item:hover {
  background-color: rgba(81, 176, 222, 0.08);
}

/* ==========================================================================
   CORE SERVICES: Asymmetric Industrial Bento Matrix & Card Hover
   ========================================================================== */
.bento-card {
  border: 1px solid rgba(123, 121, 121, 0.22);
  background-color: #FFFFFF;
  transition: border-color 0.3s cubic-bezier(0.16, 1, 0.3, 1),
              box-shadow 0.3s ease;
}

.bento-card:hover {
  border-color: var(--color-brand-blue);
  box-shadow: 0 8px 24px -6px rgba(37, 46, 75, 0.12);
}

.bento-card .card-img-wrap {
  overflow: hidden;
}

.bento-card .card-img-wrap img {
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: transform;
}

.bento-card:hover .card-img-wrap img {
  transform: scale(1.03);
}

.bento-card .action-arrow {
  transition: transform 0.25s ease;
}

.bento-card:hover .action-arrow {
  transform: translateX(4px);
}

/* Legacy utility support */
.tech-card,
.product-card,
.service-block {
  border: 1px solid rgba(123, 121, 121, 0.22);
  background-color: #FFFFFF;
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

.tech-card:hover,
.product-card:hover,
.service-block:hover {
  border-color: var(--color-brand-blue);
  box-shadow: 0 8px 24px -6px rgba(37, 46, 75, 0.1);
}

.tech-card-dark {
  border: 1px solid rgba(81, 176, 222, 0.2);
  background-color: rgba(26, 31, 38, 0.85);
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

.tech-card-dark:hover {
  border-color: var(--color-brand-blue);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4);
}

/* ==========================================================================
   1. (Continued) Mobile Swipe Carousel (pointer: coarse)
   ========================================================================== */
@media (pointer: coarse) and (max-width: 768px) {
  .mobile-swipe-carousel {
    display: flex !important;
    overflow-x: auto !important;
    scroll-snap-type: x mandatory !important;
    scroll-behavior: smooth !important;
    -webkit-overflow-scrolling: touch !important;
    gap: 1rem !important;
    padding: 0.5rem 0.25rem 1rem 0.25rem !important;
    scrollbar-width: none !important;
  }
  .mobile-swipe-carousel::-webkit-scrollbar {
    display: none !important;
  }
  .mobile-swipe-carousel > * {
    flex: 0 0 86% !important;
    max-width: 86% !important;
    scroll-snap-align: start !important;
  }
}

.carousel-dots {
  display: none;
}

@media (pointer: coarse) and (max-width: 768px) {
  .carousel-dots {
    display: flex !important;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 1rem;
    margin-bottom: 0.5rem;
  }
}

.carousel-dot {
  display: inline-block;
  height: 4px;
  width: 12px;
  border-radius: 0 !important;
  background-color: rgba(123, 121, 121, 0.35);
  transition: width 0.25s ease, background-color 0.25s ease;
  cursor: pointer;
}

.carousel-dot.active {
  width: 24px !important;
  background-color: var(--color-brand-blue) !important;
}

/* ==========================================================================
   2. IMAGE REVEAL: Crisp photography display with smooth hover zoom
   ========================================================================== */
.photo-reveal-container {
  overflow: hidden;
  position: relative;
}

.photo-reveal {
  opacity: 1;
  transform: scale(1.0);
  transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.5s ease;
  will-change: transform;
}

.photo-reveal.is-revealed {
  opacity: 1 !important;
  transform: scale(1.0) !important;
}

/* ==========================================================================
   4. PRIMARY CTA MICRO-INTERACTION (Magnetic Hover on Single Orange Button)
   ========================================================================== */
.btn-primary-orange {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background-color: var(--color-accent-orange);
  color: #FFFFFF;
  font-weight: 600;
  border: 1px solid transparent;
  will-change: transform;
  transition: background-color 0.15s ease, border-color 0.15s ease, transform 0.15s ease-out;
}

.btn-primary-orange:hover {
  background-color: #de5a10;
}

/* Technical Outlined Buttons (Navy or Brand Blue) */
.btn-outline-navy {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background-color: transparent;
  color: #FFFFFF;
  font-weight: 600;
  border: 1px solid rgba(81, 176, 222, 0.5);
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.btn-outline-navy:hover {
  background-color: var(--color-brand-blue);
  border-color: var(--color-brand-blue);
  color: var(--color-primary-navy);
}

.btn-outline-blue {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background-color: transparent;
  color: var(--color-brand-blue);
  font-weight: 600;
  border: 1px solid var(--color-brand-blue);
  transition: background-color 0.15s ease, color 0.15s ease;
}

.btn-outline-blue:hover {
  background-color: rgba(81, 176, 222, 0.12);
  border-color: var(--color-brand-blue);
}

.btn-solid-blue {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background-color: var(--color-brand-blue);
  color: var(--color-primary-navy);
  font-weight: 600;
  border: 1px solid var(--color-brand-blue);
  transition: background-color 0.15s ease, border-color 0.15s ease;
}

.btn-solid-blue:hover {
  background-color: #41a4d4;
  border-color: #41a4d4;
}

/* ==========================================================================
   5. PAGE TRANSITIONS: View Transitions API
   ========================================================================== */
@view-transition {
  navigation: auto;
}

::view-transition-old(root) {
  animation: vt-fade-out 0.22s cubic-bezier(0.4, 0, 1, 1) both;
}

::view-transition-new(root) {
  animation: vt-fade-in 0.22s cubic-bezier(0, 0, 0.2, 1) both;
}

@keyframes vt-fade-out {
  from { opacity: 1; }
  to { opacity: 0; }
}

@keyframes vt-fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* ==========================================================================
   Category Tabs (products.html)
   ========================================================================== */
.tab-btn {
  font-weight: 500;
  border: 1px solid rgba(123, 121, 121, 0.25);
  transition: border-color 0.15s ease, background-color 0.15s ease, color 0.15s ease;
}

.tab-btn-active {
  background-color: var(--color-primary-navy) !important;
  color: #FFFFFF !important;
  border-color: var(--color-primary-navy) !important;
}

.tab-btn-inactive {
  background-color: #FFFFFF !important;
  color: var(--color-primary-navy) !important;
  border-color: rgba(123, 121, 121, 0.25) !important;
}

.tab-btn-inactive:hover {
  border-color: var(--color-brand-blue) !important;
  color: var(--color-brand-blue) !important;
}

/* ==========================================================================
   Clientele Marquee: Technical, quiet, smooth
   ========================================================================== */
.marquee-container {
  position: relative;
  width: 100%;
  overflow: hidden;
  padding: 0.5rem 0;
  mask-image: linear-gradient(to right, transparent, black 8%, black 92%, transparent);
  -webkit-mask-image: linear-gradient(to right, transparent, black 8%, black 92%, transparent);
}

.marquee-track {
  display: flex;
  width: max-content;
  align-items: center;
  gap: 1.5rem;
  animation: marqueeLoop 65s linear infinite;
}

.marquee-container:hover .marquee-track {
  animation-play-state: paused;
}

@keyframes marqueeLoop {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* ==========================================================================
   Project Dossier & Technical Ledger Styles
   ========================================================================== */
.project-dossier-card {
  border: 1px solid rgba(81, 176, 222, 0.22);
  background: #1A1F26;
  transition: border-color 0.3s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.3s ease;
}

.project-dossier-card:hover {
  border-color: var(--color-brand-blue);
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.45);
}

.project-dossier-card .dossier-img-wrap {
  overflow: hidden;
  position: relative;
}

.project-dossier-card .dossier-img-wrap img {
  transition: transform 0.65s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: transform;
}

.project-dossier-card:hover .dossier-img-wrap img {
  transform: scale(1.03);
}

.compliance-ledger-row {
  border-bottom: 1px solid rgba(123, 121, 121, 0.2);
  transition: background-color 0.2s ease, border-color 0.2s ease;
}

.compliance-ledger-row:last-child {
  border-bottom: none;
}

.compliance-ledger-row:hover {
  background-color: rgba(81, 176, 222, 0.05);
  border-color: var(--color-brand-blue);
}

.btn-chamfer {
  clip-path: polygon(0 0, calc(100% - 7px) 0, 100% 7px, 100% 100%, 0 100%);
}

/* ==========================================================================
   Mobile-First (80% Users): Persistent Bottom Quick-Action Bar
   ========================================================================== */
.mobile-action-bar {
  display: none;
}

@media (max-width: 768px) {
  .mobile-action-bar {
    display: flex;
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 56px;
    background-color: #252E4B;
    border-top: 1px solid rgba(81, 176, 222, 0.3);
    z-index: 999;
  }
  
  .mobile-action-btn {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: #FFFFFF;
    font-size: 11px;
    font-weight: 600;
    text-decoration: none;
    gap: 3px;
    transition: background-color 0.15s ease, color 0.15s ease;
    border-right: 1px solid rgba(81, 176, 222, 0.15);
    -webkit-tap-highlight-color: transparent;
  }
  
  .mobile-action-btn:last-child {
    border-right: none;
  }
  
  .mobile-action-btn:hover,
  .mobile-action-btn:active {
    background-color: rgba(81, 176, 222, 0.15);
    color: var(--color-brand-blue);
  }

  .mobile-action-btn.primary,
  .mobile-action-btn.action-primary {
    background-color: var(--color-accent-orange);
    color: #FFFFFF;
    font-weight: 700;
  }

  .mobile-action-btn.primary:hover,
  .mobile-action-btn.primary:active,
  .mobile-action-btn.action-primary:hover,
  .mobile-action-btn.action-primary:active {
    background-color: #de5a10;
  }

  /* Prevent page bottom content from being obscured by bottom bar */
  body {
    padding-bottom: 56px !important;
  }
}

/* ==========================================================================
   Motion Discipline: Respect reduced motion throughout
   ========================================================================== */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  .derrick-svg-line {
    animation: none !important;
    stroke-dashoffset: 0 !important;
    opacity: 0.35 !important;
  }
  .photo-reveal {
    clip-path: none !important;
    transform: none !important;
    transition: none !important;
  }
  .card-tilt {
    transform: none !important;
  }
  .btn-primary-orange {
    transform: none !important;
  }
  .marquee-track {
    animation: none;
    overflow-x: auto;
  }
  ::view-transition-old(root),
  ::view-transition-new(root) {
    animation: none !important;
  }
}

/* ==========================================================================
   PHASE 2: TECHNICAL VISUAL SYSTEM & CORNER BRACKETS
   Precision industrial accents: section badges, technical corner brackets,
   machine dividers, and subtle line metadata.
   ========================================================================== */
.tech-corner-bracket {
  position: relative;
}

.tech-corner-bracket::before,
.tech-corner-bracket::after {
  content: '';
  position: absolute;
  width: 10px;
  height: 10px;
  border-color: var(--color-brand-blue);
  pointer-events: none;
  opacity: 0.7;
  transition: opacity 0.2s ease, border-color 0.2s ease;
}

.tech-corner-bracket::before {
  top: -1px;
  left: -1px;
  border-top: 2px solid;
  border-left: 2px solid;
}

.tech-corner-bracket::after {
  bottom: -1px;
  right: -1px;
  border-bottom: 2px solid;
  border-right: 2px solid;
}

.tech-corner-bracket:hover::before,
.tech-corner-bracket:hover::after {
  opacity: 1;
  border-color: var(--color-accent-orange);
}

.sec-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  padding: 4px 10px;
  background-color: rgba(81, 176, 222, 0.1);
  border: 1px solid rgba(81, 176, 222, 0.3);
  color: var(--color-brand-blue);
}

.sec-badge-dot {
  width: 6px;
  height: 6px;
  background-color: var(--color-brand-blue);
  display: inline-block;
}

.sec-badge-orange {
  background-color: rgba(243, 103, 23, 0.1);
  border-color: rgba(243, 103, 23, 0.35);
  color: var(--color-accent-orange);
}

.sec-badge-orange .sec-badge-dot {
  background-color: var(--color-accent-orange);
}

/* Breadcrumbs */
.enserv-breadcrumb {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #94A3B8;
}

.enserv-breadcrumb a {
  color: #CBD5E1;
  text-decoration: none;
  transition: color 0.15s ease;
}

.enserv-breadcrumb a:hover {
  color: var(--color-brand-blue);
}

.enserv-breadcrumb .separator {
  color: #64748B;
}

.enserv-breadcrumb .current {
  color: var(--color-brand-blue);
  font-weight: 600;
}

/* ==========================================================================
   PHASE 2: ENGINEERING PROJECT DOSSIER LAYOUT
   ========================================================================== */
.dossier-card {
  background-color: #FFFFFF;
  border: 1px solid #CBD5E1;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.03);
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
  position: relative;
}

.dossier-card:hover {
  border-color: var(--color-brand-blue);
  box-shadow: 0 8px 24px rgba(37, 46, 75, 0.08);
}

.dossier-number {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--color-brand-blue);
  background-color: rgba(81, 176, 222, 0.12);
  padding: 4px 8px;
  border: 1px solid rgba(81, 176, 222, 0.3);
  display: inline-block;
}

.dossier-grid {
  display: grid;
  grid-template-columns: 1fr;
}

@media (min-width: 1024px) {
  .dossier-grid {
    grid-template-columns: 5fr 7fr;
  }
}

.dossier-meta-table {
  width: 100%;
  border-collapse: collapse;
  font-family: var(--font-mono);
  font-size: 12px;
}

.dossier-meta-table tr {
  border-bottom: 1px solid #E2E8F0;
}

.dossier-meta-table tr:last-child {
  border-bottom: none;
}

.dossier-meta-table th {
  text-align: left;
  padding: 8px 12px;
  background-color: #F8FAFC;
  color: #64748B;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  width: 38%;
  border-right: 1px solid #E2E8F0;
  vertical-align: top;
}

.dossier-meta-table td {
  padding: 8px 12px;
  color: #1E293B;
  font-weight: 500;
  vertical-align: top;
}

.dossier-gallery-strip {
  display: flex;
  gap: 8px;
  margin-top: 10px;
}

.dossier-thumb {
  width: 64px;
  height: 48px;
  object-fit: cover;
  border: 1px solid #CBD5E1;
  cursor: pointer;
  transition: transform 0.15s ease, border-color 0.15s ease;
}

.dossier-thumb:hover {
  transform: scale(1.05);
  border-color: var(--color-brand-blue);
}

/* Category Filter Tabs */
.filter-btn {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 8px 16px;
  background-color: #F1F5F9;
  border: 1px solid #CBD5E1;
  color: #475569;
  cursor: pointer;
  transition: all 0.2s ease;
}

.filter-btn:hover {
  background-color: #E2E8F0;
  color: #0F172A;
  border-color: #94A3B8;
}

.filter-btn.active {
  background-color: var(--color-primary-navy);
  border-color: var(--color-primary-navy);
  color: #FFFFFF;
}

/* ==========================================================================
   PHASE 2: ACCESSIBLE IMAGE LIGHTBOX
   ========================================================================== */
.enserv-lightbox {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background-color: rgba(15, 20, 28, 0.96);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 20px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.enserv-lightbox.active {
  opacity: 1;
  pointer-events: auto;
}

.lightbox-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: #FFFFFF;
  padding: 4px 10px;
  z-index: 10;
}

.lightbox-counter {
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--color-brand-blue);
}

.lightbox-close-btn {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.3);
  color: #FFFFFF;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.lightbox-close-btn:hover,
.lightbox-close-btn:focus-visible {
  border-color: var(--color-accent-orange);
  color: var(--color-accent-orange);
  outline: none;
}

.lightbox-stage {
  position: relative;
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px;
  overflow: hidden;
}

.lightbox-image {
  max-width: 90vw;
  max-height: 80vh;
  object-fit: contain;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.8);
  border: 1px solid rgba(81, 176, 222, 0.3);
  transition: transform 0.2s ease;
}

.lightbox-nav-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(26, 31, 38, 0.8);
  border: 1px solid rgba(81, 176, 222, 0.4);
  color: #FFFFFF;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  z-index: 10;
}

.lightbox-nav-btn:hover,
.lightbox-nav-btn:focus-visible {
  background: var(--color-brand-blue);
  color: var(--color-primary-navy);
  outline: none;
}

.lightbox-nav-prev {
  left: 20px;
}

.lightbox-nav-next {
  right: 20px;
}

.lightbox-caption {
  text-align: center;
  color: #CBD5E1;
  font-family: var(--font-mono);
  font-size: 13px;
  padding: 8px 16px;
  background-color: rgba(26, 31, 38, 0.9);
  border: 1px solid rgba(81, 176, 222, 0.2);
  max-width: 800px;
  margin: 0 auto;
}

/* ==========================================================================
   PHASE 2: PRODUCT CATALOGUE SEARCH & SPEC MODAL
   ========================================================================== */
.catalogue-search-bar {
  display: flex;
  align-items: center;
  background-color: #F8FAFC;
  border: 1px solid #CBD5E1;
  padding: 4px 12px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.catalogue-search-bar:focus-within {
  border-color: var(--color-brand-blue);
  box-shadow: 0 0 0 2px rgba(81, 176, 222, 0.2);
  background-color: #FFFFFF;
}

.catalogue-search-input {
  width: 100%;
  border: none;
  background: transparent;
  padding: 10px 8px;
  font-size: 14px;
  color: #0F172A;
  outline: none;
}

.catalogue-search-input::placeholder {
  color: #94A3B8;
  font-family: var(--font-mono);
  font-size: 13px;
}

/* Product Spec Modal */
.product-spec-modal {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background-color: rgba(15, 20, 28, 0.8);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

.product-spec-modal.active {
  opacity: 1;
  pointer-events: auto;
}

.product-spec-dialog {
  background-color: #FFFFFF;
  border: 2px solid var(--color-primary-navy);
  max-width: 640px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.3);
  transform: translateY(20px);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
}

.product-spec-modal.active .product-spec-dialog {
  transform: translateY(0);
}

.product-spec-header {
  background-color: var(--color-primary-navy);
  color: #FFFFFF;
  padding: 16px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 2px solid var(--color-brand-blue);
}

.product-spec-body {
  padding: 24px;
}

/* ==========================================================================
   PHASE 2: RFQ FORM VALIDATION & CONFIRMATION MODAL
   ========================================================================== */
.rfq-input-invalid {
  border-color: #EF4444 !important;
  background-color: #FEF2F2 !important;
}

.rfq-input-valid {
  border-color: #10B981 !important;
}

.rfq-error-text {
  color: #DC2626;
  font-size: 11px;
  font-family: var(--font-mono);
  margin-top: 4px;
  display: block;
}

.rfq-dropzone {
  border: 2px dashed #CBD5E1;
  background-color: #F8FAFC;
  padding: 16px;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.rfq-dropzone:hover,
.rfq-dropzone.dragover {
  border-color: var(--color-brand-blue);
  background-color: rgba(81, 176, 222, 0.05);
}

.file-preview-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background-color: #E2E8F0;
  border: 1px solid #94A3B8;
  padding: 4px 10px;
  font-family: var(--font-mono);
  font-size: 11px;
  color: #1E293B;
  margin-top: 8px;
}

/* RFQ Ready to Submit Dispatch Modal */
.rfq-dispatch-modal {
  position: fixed;
  inset: 0;
  z-index: 10000;
  background-color: rgba(15, 20, 28, 0.85);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

.rfq-dispatch-modal.active {
  opacity: 1;
  pointer-events: auto;
}

.rfq-dispatch-dialog {
  background-color: #FFFFFF;
  border: 2px solid var(--color-brand-blue);
  max-width: 580px;
  width: 100%;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.4);
  padding: 28px;
  position: relative;
}

/* ==========================================================================
   PHASE 2: REGIONAL PRESENCE MAP (LIGHTWEIGHT SVG & INTERACTIVE PINS)
   ========================================================================== */
.regional-map-box {
  background-color: #1A1F26;
  border: 1px solid rgba(81, 176, 222, 0.25);
  position: relative;
  overflow: hidden;
}

.map-pin {
  cursor: pointer;
  transition: transform 0.2s ease;
}

.map-pin:hover {
  transform: scale(1.3);
}

.map-pin-pulse {
  animation: mapPulse 2s infinite ease-in-out;
  transform-origin: center;
}

@keyframes mapPulse {
  0% { r: 6px; opacity: 0.8; }
  50% { r: 14px; opacity: 0.2; }
  100% { r: 6px; opacity: 0.8; }
}

.map-tooltip {
  position: absolute;
  background-color: #0F172A;
  border: 1px solid var(--color-brand-blue);
  padding: 8px 12px;
  font-family: var(--font-mono);
  font-size: 11px;
  color: #FFFFFF;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.15s ease;
  z-index: 20;
  white-space: nowrap;
}

.map-tooltip.active {
  opacity: 1;
}

/* ==========================================================================
   PHASE 3: ENGINEERING CASE DOSSIER DETAIL MODAL
   ========================================================================== */
.project-dossier-modal {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background-color: rgba(15, 20, 28, 0.85);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

.project-dossier-modal.active {
  opacity: 1;
  pointer-events: auto;
}

.project-dossier-dialog {
  background-color: #FFFFFF;
  border: 2px solid var(--color-primary-navy);
  max-width: 920px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.35);
  transform: translateY(20px);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
}

.project-dossier-modal.active .project-dossier-dialog {
  transform: translateY(0);
}

