/* ===========================
   GLOBAL BASE
   =========================== */
body {
  margin: 0;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Helvetica Neue', Arial, sans-serif;
  background: #07090f;
  color: white;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

html {
  scroll-behavior: smooth;
}

header {
  background: black;
  position: fixed;
  width: 100%;
  top: 0;
  left: 0;
  z-index: 5000 !important;
  transition: transform 0.25s ease;
}
header::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.25); /* adjust darkness */
  z-index: 1;
  pointer-events: none;
}

#dotMatrix {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  opacity: 1;
  z-index: 0 !important;
}

body {
  padding-top: 0;
}

nav {
  width: 100%;
  max-width: 100%;
  margin: auto;
  display: flex;
  justify-content: center;      /* ⭐ stop stretching */
  align-items: center;
  padding: 6px 16px;            /* ⭐ fix typo */
  flex-wrap: wrap;
  position: relative;
  box-sizing: border-box;
  position: relative;
  z-index: 2;
  isolation: isolate !important;
  will-change: transform;
}

nav .dropdown {
  position: relative;
  display: inline-block;
}

.dropdown-content {
  position: absolute;
  top: 100%;
  left: 0;                 /* ⭐ aligns under Scoreboards */
  display: none;
  background: #0e131c;
  min-width: 180px;
  padding: 10px 0;
  border-radius: 8px;
  border: 1px solid #00ff88;
  z-index: 99999;
}

nav .dropdown:hover .dropdown-content {
  display: block;
}


nav a {
  color: white;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  position: relative !important;
  z-index: 6002 !important;
  isolation: isolate !important;
  text-shadow:
    -1px -1px 0 rgba(0, 0, 0, 0.3),
     1px -1px 0 rgba(0, 0, 0, 0.3),
    -1px  1px 0 rgba(0, 0, 0, 0.3),
     1px  1px 0 rgba(0, 0, 0, 0.3),
    0 2px 6px rgba(0, 0, 0, 0.6),
    0 0 6px rgba(0, 255, 136, 0.25) !important;
}


nav a:hover {
  color: #00ff88;
}

.logo {
  font-family: 'Orbitron', 'Arial Black', 'Impact', sans-serif;
  font-size: 48px;
}
.logo span:nth-child(-n+3) {
  letter-spacing: -0.22em; /* scales with font size */
}

/* ===========================
   HERO
   =========================== */
.hero {
  position: relative;
  height: 70vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: url("images/hero.jpg") center/cover no-repeat;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  z-index: 1;
}

.hero h1 {
  position: relative;
  z-index: 2;
  font-family: 'Orbitron', 'Arial Black', 'Impact', sans-serif;
  font-size: 70px;
  color: #00ff88;
  padding: 20px 40px;
  background: rgba(0, 0, 0, 0.5);
  border-radius: 12px;
  text-shadow: 0 0 15px rgba(0, 255, 136, 0.6);
  opacity: 0;
  animation: fadeInGlow 2s forwards;
}

/* ===========================
   SECTION DIVIDER
   =========================== */
.sectionDivider {
  border: 0;
  border-top: 1px solid #ffffffff;
  width: 80%;
  margin: 50px auto;
}

/* ===========================
   TESTIMONIALS
   =========================== */
.testimonial {
  background: #1f2a3e;
  border-left: 3px solid #00ff88;
  padding: 20px;
  margin: 25px auto;
  max-width: 900px;
  border-radius: 8px;
  color: #ccc;
  line-height: 1.6;
}

.testimonial strong {
  display: block;
  margin-top: 10px;
  color: #00ff88;
  font-size: 16px;
}

#testimonialList {
  max-height: 400px;
  overflow-y: auto;
  display: block;
}

#testimonialList::-webkit-scrollbar {
  width: 8px;
}

#testimonialList::-webkit-scrollbar-thumb {
  background: #00ff88;
  border-radius: 4px;
}

#testimonialList::-webkit-scrollbar-track {
  background: #0e131c;
}

/* ===========================
   ABOUT / PRODUCTS SPACING FIX
   =========================== */
#aboutDBIT h2 {
  position: relative;
}

#products h2 {
  margin-top: 0;
}

/* Neon glow for section headings */
section h2,
.sectionTitle,
.productGroupTitle {
  color: #ffffff;
  text-shadow:

    0 0 12px #00ff88
}

.productGroup {
  padding-top: 0;
}

/* ===========================
   HEADINGS
   =========================== */
section h2 {
  font-family: 'Orbitron', 'Arial Black', 'Impact', sans-serif;
  text-align: center;
  margin-bottom: 50px;
  font-size: 48px;
}

/* ===========================
   SECTION BASE
   =========================== */
section {
  max-width: 1200px;
  margin: auto;
  padding: 40px 10px;
}

/* ===========================
   PRODUCT GRID
   =========================== */
.products {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 15px;
  width: 100%;
  box-sizing: border-box;
}

/* ===========================
   PRODUCT CARD (DESKTOP)
   =========================== */
.card {
  background: #1f2a3e;
  border-radius: 8px;
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
  flex: 0 1 calc(33.333% - 85px);
  max-width: 380px;
  min-width: 280px;
  display: flex;
  flex-direction: column;
  margin-bottom: 25px;
  margin-top: 25px;
  margin-right: 25px;
  box-sizing: border-box;
}

.card img:hover {
  opacity: 0.9;
}

.cardContent {
  padding: 12px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.cardChin {
  background: #3d765c;
  border-top: 1px solid #00ff88;
  padding: 10px 12px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
}

.price {
  color: #00ff88;
  font-size: 20px;
  font-weight: 700;
}

/* ===========================
   BUTTONS
   =========================== */
button {
  padding: 8px 14px;
  border: none;
  border-radius: 6px;
  background: #00ff88;
  color: #000;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s, transform 0.1s;
  font-family: inherit;
}

button:hover {
  background: #00ffaa;
  box-shadow: 0 0 16px #00ffaa;
}

button:active {
  transform: scale(0.98);
}

.demoBtn {
  padding: 8px 16px;
  font-size: 14px;
  min-width: 70px;
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ===========================
   LIGHTBOX / MODALS
   =========================== */
.lightbox {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, .9);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 9999;
}

.lightbox img {
  max-width: 90%;
  max-height: 90%;
}

#map {
  height: 500px;
  border-radius: 12px;
}

.contact {
  text-align: center;
  padding-bottom: 10px;
}

/* ===========================
   MODAL CONTENT
   =========================== */
.modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100dvw !important;   /* dynamic viewport width */
  height: 100%;
  background: rgba(0, 0, 0, .9);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  max-width: 100%;
  overflow-x: hidden !important;
}

#lightbox,
#videoModal {
  z-index: 10001;
}

.modal iframe {
  max-width: 90%;
  max-height: 90%;
}

#infoModalContent {
  display: flex;
  flex-direction: row;
  gap: 0;
  align-items: flex-start;
  max-width: 1100px;
  width: 90vw;
  max-height: 80vh;
  overflow: hidden;
  background: #111820;
  padding: 0;
  border-radius: 16px;
  border: 1px solid #1a2530;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.8);
  position: relative;
}

.modalClose {
  position: fixed !important;
  top: 20px !important;
  right: 20px !important;
  width: 40px;
  height: 40px;
  border: none;
  background: rgba(0,0,0,0.6);
  color: white;
  font-size: 26px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  cursor: pointer;
  z-index: 100000 !important;
}



.modalClose:hover {
  background: rgba(0, 255, 136, 0.3);
}

.modalTitle {
  font-size: 24px;
  color: #00ff88;
  margin: 0 0 16px 0;
  font-weight: 700;
}

.modalImageColumn {
  flex: 0 0 35%;
  display: flex;
  flex-direction: column;
  background: #0a0f14;
  border-radius: 16px 0 0 16px;
  overflow: hidden;
}

.modalImageColumn img {
  height: 400px !important;       /* ⭐ same as product card */
  width: auto !important;
  max-width: none !important;
  object-fit: cover !important;   /* ⭐ crop sides */
  object-position: center !important;
  display: block !important;
  flex: 0 0 auto !important;
  align-self: center !important;
}


.modalChin {
  background: #0a0f14;
  border-top: 1px solid #00ff8840;
  padding: 12px 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.modalChin .price {
  font-size: 20px;
  font-weight: 700;
  color: #00ff88;
}

.modalChin .demoBtn {
  padding: 8px 16px;
  font-size: 13px;
}

.modalDescColumn {
  flex: 1;
  padding: 24px;
  overflow-y: auto;
  max-height: 80vh;
  color: #ccc;
  line-height: 1.6;
  font-size: 14px;
}

.modalDescColumn h2,
.modalDescColumn h3,
.modalDescColumn strong {
  color: #00ff88;
  margin-top: 20px;
  margin-bottom: 10px;
}

.modalDescColumn h2:first-child,
.modalDescColumn h3:first-child {
  margin-top: 0;
}

.modalDescColumn p {
  margin-bottom: 12px;
}

/* ===========================
   FOOTER
   =========================== */
footer {
  text-align: right;
  padding: 30px;
  background: black;
  color: #777;
}

/* ===========================
   PRODUCT DESCRIPTION
   =========================== */
.productInfo {
  color: white;
  font-size: 14px;
  line-height: 1.5;
  flex: 1;
}

.productInfo strong {
  display: block;
  font-size: 24px;
  margin-bottom: 6px;
  color: #ffffff;
  line-height: 1.2;
  font-weight: 700;
}

.learnMore {
  display: block;
  margin-top: 8px;
  font-size: 12px;
  color: #00ff88;
  opacity: 0.7;
  font-style: italic;
}

/* ===========================
   RESPONSIVE BREAKPOINTS
   =========================== */
@media (max-width: 1024px) {
  .card {
    flex: 0 1 calc(50% - 15px);
  }
  
  nav {
    padding: 12px;
    z-index: 6001 !important;
  }
  
  .logo {
    font-size: 36px;
  }
  
  section h2 {
    font-size: 40px;
    margin-bottom: 30px;
  }
}

/* ============================================
   MOBILE LAYOUT — CLEAN MERGED VERSION
   ============================================ */
@media (max-width: 768px) {

  nav .dropdown {
    flex-basis: auto !important;
    width: auto !important;
  }

 .card:not(.heroProduct) {
    flex-direction: column !important;
    flex: 0 1 auto;
    width: auto !important;
    max-width: 100% !important;
    display: flex;
    box-sizing: border-box;
    margin: 0 auto 25px auto !important;
    align-items: center !important;
    padding-top: 10px; /* adjust to taste */
  }

  /* Base mobile image rule */
  .card img {
    height: 300px !important;
    width: auto !important;
    max-width: none !important;
    object-fit: cover !important;
    object-position: center !important;
    display: block !important;
    margin-left: auto !important;
    margin-right: auto !important;
  }

  /* ⭐ FINAL OVERRIDE — MUST COME AFTER THE ABOVE */
  .card:not(.heroProduct) img {
    height: 100px !important;
    background: red !important;
  }

  .cardContent {
    width: 100%;
    padding: 12px;
  }

  .cardChin {
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 auto !important;
    padding: 8px 12px;
    display: flex;
    justify-content: space-between !important;
    align-items: center;
    box-sizing: border-box;
  }

  /* -------------------------
     MODAL (mobile)
     ------------------------- */

  /* Entire modal scrolls */
  #infoModalContent {
    flex-direction: column !important;
    width: 95vw !important;
    max-height: 90vh !important;
    align-items: stretch !important;
    overflow-y: auto !important;
    overflow-x: hidden !important;
  }

  /* Image column full width */
  .modalImageColumn {
    width: 100% !important;
    display: flex;
    justify-content: center;
    border-radius: 16px 16px 0 0;
  }

  .modalImageColumn img {
    height: 200px !important;
    width: auto !important;
    max-width: none !important;
    object-fit: cover !important;
    object-position: center !important;
    display: block !important;
    margin-left: auto !important;
    margin-right: auto !important;
  }

  /* Description full width, no internal scroll */
  .modalDescColumn {
    width: 100% !important;
    max-width: 100% !important;
    padding: 20px;
    max-height: none !important;
    overflow: visible !important;
    box-sizing: border-box !important;
    overflow-wrap: break-word !important;
    word-break: break-word !important;
  }

  /* Chin bar full width, price left, button right */
  .modalChin {
    width: 100% !important;
    max-width: 100% !important;
    padding: 12px 16px;
    display: flex !important;
    flex-direction: row !important;
    justify-content: space-between !important;
    align-items: center !important;
    box-sizing: border-box;
    gap: 8px;
    border-radius: 0 0 16px 16px;
  }

  .modalChin .price {
    margin-right: auto !important;
  }

  .modalChin button,
  .modalChin .demoBtn {
    margin-left: auto !important;
    width: auto !important;
    flex-shrink: 0 !important;
  }
/* ============================================
   FORCE HERO PRODUCT TO USE GRID ON MOBILE
   ============================================ */
  .heroProduct {
    display: grid !important;                 /* ⭐ override flexbox */
    grid-template-columns: 1fr !important;
    grid-template-rows: auto auto auto !important;
    width: 100% !important;
    max-width: 100% !important;
    align-items: start !important;
    box-sizing: border-box;
  }

  .heroProduct img {
    grid-column: 1 !important;
    grid-row: 1 !important;
    width: 100% !important;
    height: auto !important;
    max-height: 300px !important;
    object-fit: cover !important;
  }

  .heroProduct .cardContent {
    grid-column: 1 !important;
    grid-row: 2 !important;
  }

  .heroProduct .cardChin {
    grid-column: 1 !important;
    grid-row: 3 !important;
    margin-top: 10px;
  }
  /* ============================================
    BULLETPROOF MOBILE HEADER + NAV (FINAL FIX)
    ============================================ */

  /* Force header to fit screen */
  header {
    width: 100% !important;
    max-width: 100% !important;
    overflow-x: hidden !important;
    margin: 0 !important;
    padding: 0 !important;
    box-sizing: border-box !important;
  }

  /* AUTO-SHRINK LOGO ON MOBILE */
  .logo {
    font-size: clamp(16px, 8vw, 32px) !important;
    white-space: nowrap !important;     /* ⭐ no wrapping */
    overflow: hidden !important;
    text-overflow: ellipsis;            /* optional */
    max-width: 100% !important;
    display: block !important;
    text-align: center !important;
    margin: 0 auto 10px auto !important;
    line-height: 1.1 !important;
  }
  /* Nav container must wrap AND fit viewport */
  nav {
    display: flex !important;
    flex-wrap: wrap !important;           /* ⭐ allows wrapping */
    justify-content: center !important;
    align-items: center !important;

    width: 100% !important;
    max-width: 100% !important;

    padding: 6px 12px !important;         /* ⭐ FIXED padding */
    margin: 0 !important;
    box-sizing: border-box !important;
    overflow-x: hidden !important;
    gap: 6px !important;
    z-index: 6001 !important;
  }

  /* Nav links must NOT push width */
  nav a {
    white-space: nowrap !important;
    font-size: 14px !important;
    padding: 4px 6px !important;
    max-width: 100% !important;
  }



}


@media (max-width: 480px) {

  .hero h1 {
    font-size: 28px;
    padding: 12px 20px;
  }
  
  .logo {
    font-size: 24px;
    white-space: normal !important;        /* ⭐ allow wrapping */
    overflow-wrap: break-word !important;  /* ⭐ prevent overflow */
    text-align: center !important;
  }
  
  section h2 {
    font-size: 24px;
  }
  
  nav a {
    margin: 2px 4px !important;            /* ⭐ prevent nav overflow */
    font-size: 12px !important;
  }

  .card {
    min-height: 140px;
  }
  
  .productInfo {
    font-size: 12px;
  }
  
  .productInfo strong {
    font-size: 17px;
  }
  
  .price {
    font-size: 16px;
  }
}

/* ===========================
   FIXED CARD CHIN
   =========================== */
.cardChin {
  width: 100%;
  padding: 8px 12px;
  border-top: 1px solid #00ff88;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 52px;
  box-sizing: border-box;
}

.cardChin .price {
  margin: 0;
  white-space: nowrap;
  flex-shrink: 0;
}

.cardChin .demoBtn {
  margin-left: auto;
  flex-shrink: 0;
  white-space: nowrap;
}

/* ===========================
   HERO PRODUCT GRID (unchanged)
   =========================== */
.heroProduct {
  width: 100%;
  display: grid;
  grid-template-columns: 45% 55%;
  grid-template-rows: auto auto;
  gap: 20px;
  padding: 20px;
  margin-bottom: 40px;
  border: 2px solid #00ff88;
  box-shadow: 0 0 25px rgba(0, 255, 136, 0.4);
}

.heroProduct img {
  grid-column: 1;
  grid-row: 1;
  width: 100%;
  height: auto;
  max-height: 420px;
  object-fit: cover;
  object-position: center;
}

.heroProduct .cardContent {
  grid-column: 2;
  grid-row: 1;
  display: flex;
  flex-direction: column;
  padding: 10px 0;
  font-size: 18px;
}

.heroProduct .cardChin {
  grid-column: 2;
  grid-row: 2;
  margin-top: 10px;
  font-size: 20px;
  display: flex;
  gap: 16px;
  align-items: center;
}



.heroProduct {
  width: 100% !important;
  max-width: 100% !important;
  grid-column: 1 / -1 !important;
  flex: 0 0 100% !important;
}

/* ===========================
   PREVIEW TEXT
   =========================== */
/* Make preview text paragraphs behave like inline text */
/* All preview paragraphs behave normally */
.previewText p {
  display: block;
  margin: 0 0 6px 0;
  padding: 0;
}

/* Only the LAST paragraph becomes inline */
.previewText p:last-of-type {
  display: inline;
}

/* ...more stays on the same line */
.moreLink {
  display: inline;
  color: #00ff88 !important;
  font-weight: 700;
  cursor: pointer;
  margin-left: 4px;
  text-shadow: 0 0 6px rgba(0, 255, 136, 0.8);
}

/* Ensure the last paragraph does not break */
.previewText p:last-of-type {
  display: inline !important;
}

/* Force ...more to sit on the same line */
.moreLink {
  display: inline !important;
  color: #00ff88 !important;
  font-weight: 700;
  cursor: pointer;
  margin-left: 4px;
  text-shadow: 0 0 6px rgba(0, 255, 136, 0.8);
}

/* ===========================
   DESKTOP CARD IMAGE OVERRIDE
   =========================== */
.card:not(.heroProduct) img {
  height: 400px !important;
  width: auto !important;
  max-width: none !important;
  object-fit: cover !important;
  object-position: center !important;
  display: block !important;
  flex: 0 0 auto !important;
  align-self: center !important;
  padding-top: 10px; /* adjust to taste */
}


/* Center the entire enquiry section */
#enquiryContainer {
  text-align: center;
  width: 100%;
}

/* Center the form wrapper */
#enquiryFormWrapper {
  margin: 20px auto 0 auto;
  padding: 20px;
  background: #0a0f14;
  border: 1px solid #00ff8840;
  border-radius: 12px;
  max-width: 500px;
  text-align: left; /* keep labels left-aligned */
}

/* Neon button */
.neonBtn {
  background: #00ff88;
  color: #000;
  padding: 12px 22px;
  border: none;
  border-radius: 6px;
  font-weight: 700;
  cursor: pointer;
  font-size: 16px;
  text-shadow: 0 0 6px #00ff88;
  box-shadow: 0 0 12px #00ff88;
  transition: 0.2s ease;
  margin: 0 auto;
  display: inline-block;
}

.neonBtn:hover {
  background: #00ffaa;
  box-shadow: 0 0 16px #00ffaa;
}

/* Form fields */
#enquiryForm label {
  display: block;
  margin: 12px 0 4px;
  color: #00ff88;
  font-weight: 600;
}

#enquiryForm input,
#enquiryForm textarea {
  width: 100%;
  padding: 10px;
  background: #111820;
  border: 1px solid #00ff8840;
  border-radius: 6px;
  color: #fff;
  font-size: 15px;
  box-sizing: border-box; /* ⭐ prevents touching the frame */
}
#enquiryForm button.neonBtn {
  margin-top: 20px;
}


#enquiryForm textarea {
  height: 120px;
  resize: vertical;
}

/* Success + error messages */
.formMessage {
  display: none;
  margin-top: 12px;
  font-weight: 600;
  text-align: center;
}

.formMessage.success {
  color: #00ff88;
}

.formMessage.error {
  color: #ff4444;
}


@media (max-width: 768px) {
  .modal {
    width: 100dvw !important;
    max-width: 100% !important;
    overflow-x: hidden !important;
  }
  .modalClose {
    top: 60px !important;   /* lower the X so it’s always visible */
    right: 32px !important;
    -webkit-user-select: none;
    user-select: none;  
  }
  #contactSection .contact {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;
  }

  #contactSection img {
    margin: 20px auto 0 auto !important;
  }
  .card:not(.heroProduct) img {
    height: 200px !important;
  }
}

@keyframes fadeInGlow {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
.card,
.card * {
  -webkit-user-select: none;
  user-select: none;
}

@media (min-width: 769px) {
  nav a {
    margin: 0 14px;
  }
}
