* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

:root {
  --primary: #FF6B35;
  --secondary: #004E89;
  --accent: #1A5F7A;
  --dark: #0F0F0F;
  --light: #FFFFFF;
  --gray: #F5F5F5;
  --border: #E0E0E0;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  -webkit-tap-highlight-color: transparent;
}


body {
  line-height: 1.6;
  color: #333;
  overflow-x: hidden;
}

/* ANIMATIONS */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes slideInLeft {
  from {
    opacity: 0;
    transform: translateX(-50px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes slideInRight {
  from {
    opacity: 0;
    transform: translateX(50px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.05); }
}

@keyframes glow {
  0%, 100% { box-shadow: 0 0 20px rgba(255, 107, 53, 0.3); }
  50% { box-shadow: 0 0 40px rgba(255, 107, 53, 0.6); }
}

.wow {
  animation: fadeInUp 0.8s ease-out;
}

/* HEADER */
.header {
  position: fixed;
  top: 0;
  width: 100%;
  background: linear-gradient(135deg, var(--secondary) 0%, var(--accent) 100%);
  color: var(--light);
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 20px;
  z-index: 1000;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
}

.header.scrolled {
  padding: 8px 20px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.logo {
  font-weight: bold;
  font-size: 20px;
  letter-spacing: 1px;
  animation: slideInLeft 0.6s ease-out;
}

.logo-img {
  height: 50px;
  object-fit: contain;
  animation: slideInLeft 0.6s ease-out;
}

.phone {
  display: none;
  font-weight: 500;
}

.nav-desktop {
  display: none;
  gap: 30px;
}

.nav-desktop a {
  color: var(--light);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.3s;
}

.nav-desktop a:hover {
  color: var(--primary);
}

.hamburger {
  font-size: 26px;
  cursor: pointer;
  transition: transform 0.3s;
}

.hamburger:hover {
  transform: scale(1.1);
}

/* MOBILE MENU */
.mobile-menu {
  position: fixed;
  top: 60px;
  right: -100%;
  width: 100%;
  height: calc(100% - 60px);
  background: linear-gradient(180deg, #1a1a1a 0%, #2d2d2d 100%);
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-top: 40px;
  transition: 0.3s;
  z-index: 1200;
}

.mobile-menu a {
  color: var(--light);
  text-decoration: none;
  font-size: 22px;
  margin: 15px 0;
  transition: color 0.3s;
}

.mobile-menu a:hover {
  color: var(--primary);
}

.mobile-menu.open {
  right: 0;
}

/* HERO */
.hero {
  height: 100vh;
  background: linear-gradient(135deg, rgba(0, 78, 137, 0.35) 0%, rgba(26, 95, 122, 0.35) 100%),
              url("hero-banner.png") center/cover no-repeat;
  background-attachment: fixed;
  background-size: cover;
  background-position: center;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: var(--light);
  margin-top: 60px;
  position: relative;
  overflow: hidden;
}

/* Responsive hero adjustments for smaller devices */
@media (max-width: 768px) {
  /* header / spacing */
  .logo-img { height: 42px; }
  .header { padding: 10px 14px; }
  .hero { 
    height: 60vh; /* reduce full-screen height on small screens */
    background-attachment: scroll; /* fixed backgrounds cause issues on mobile */
    background-position: center top;
    margin-top: 60px; /* keep space for fixed header */
    padding: 0 10px;
  }

  .hamburger { font-size: 28px; }

  /* text & buttons */
  .hero h1 { font-size: clamp(24px, 8vw, 40px); }
  .hero p { font-size: 15px; }
  .hero-buttons { gap: 12px; }

  /* gallery thumbs
     reduce thumb size slightly and allow wrap on narrow devices */
  .gallery-thumbs { gap: 8px; padding: 6px 6px; }
  .gallery-thumbs .thumb img { width: 96px; height: 64px; }

  /* modal adjustments */
  #galleryModal .modal-content { padding: 0; }
  #galleryModal img#galleryImage { max-height: 70vh; }
}

.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.4);
  z-index: 1;
}

.hero-content {
  position: relative;
  z-index: 2;
  animation: fadeInUp 1s ease-out;
}

.hero h1 {
  font-size: clamp(32px, 8vw, 64px);
  margin-bottom: 20px;
  font-weight: 700;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.hero p {
  font-size: clamp(18px, 4vw, 28px);
  margin-bottom: 40px;
  letter-spacing: 2px;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
}

.hero-buttons {
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap;
}

.btn {
  display: inline-block;
  padding: 14px 40px;
  background: var(--primary);
  color: var(--light);
  text-decoration: none;
  border-radius: 50px;
  font-weight: 600;
  transition: all 0.3s ease;
  border: 2px solid var(--primary);
  cursor: pointer;
  font-size: 16px;
  box-shadow: 0 4px 15px rgba(255, 107, 53, 0.3);
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 25px rgba(255, 107, 53, 0.6);
  animation: pulse 0.6s ease-in-out;
}

.btn.secondary {
  background: transparent;
  color: var(--light);
  border: 2px solid var(--light);
}

.btn.secondary:hover {
  background: var(--light);
  color: var(--primary);
  box-shadow: 0 6px 25px rgba(255, 255, 255, 0.3);
}

/* SECTIONS */
.section {
  padding: 60px 20px;
  max-width: 1200px;
  margin: 0 auto;
  scroll-margin-top: 80px;
}

.section h2 {
  font-size: 36px;
  margin-bottom: 30px;
  color: var(--secondary);
  position: relative;
  display: inline-block;
}

.section h2::after {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 0;
  width: 60px;
  height: 4px;
  background: var(--primary);
  border-radius: 2px;
}

.section.gray {
  background: var(--gray);
}

.section p {
  font-size: 16px;
  line-height: 1.8;
  color: #555;
  margin-bottom: 20px;
}

.services {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
  margin: 40px 0;
}

.services li {
  padding: 20px;
  background: var(--light);
  border-left: 4px solid var(--primary);
  border-radius: 8px;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.services li:hover {
  transform: translateX(10px);
  box-shadow: 0 4px 15px rgba(255, 107, 53, 0.2);
}

.note {
  font-style: italic;
  color: #777;
  margin-top: 30px;
}

/* PORTFOLIO SECTION */
.portfolio {
  padding: 60px 20px;
  background: var(--gray);
}

.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 26px;
  margin-top: 28px;
  /* allow the portfolio grid to expand closer to edges on wide screens */
  max-width: none;
  width: calc(100% - 60px);
  margin-left: 30px;
  margin-right: 30px;
}

/* Optional full-bleed variant for very wide screens */
@media (min-width: 1400px) {
  .portfolio-grid { width: calc(100% - 120px); margin-left: 60px; margin-right: 60px; gap: 32px; }
}

/* Gallery grid + items */

/* Horizontal scrolling carousel */

/* Simple carousel: main image + thumbnails */
.carousel { max-width: 1100px; margin: 0 auto; }
.carousel-main { position: relative; display:flex; align-items:center; justify-content:center; margin-bottom: 14px; }
.carousel-main img { max-width: 80%; max-height: 60vh; border-radius: 8px; box-shadow: 0 12px 40px rgba(0,0,0,0.35); cursor: pointer; }
.carousel-btn { position: absolute; background: rgba(0,0,0,0.5); color: white; border: none; width:44px; height:56px; font-size:28px; cursor:pointer; border-radius:6px; }
.carousel-btn.prev { left: 8px; }
.carousel-btn.next { right: 8px; }

.carousel-thumbs { display:flex; gap:10px; overflow-x:auto; padding: 8px 12px; }
.carousel-thumbs .thumb { border: none; background: transparent; padding:0; cursor:pointer; border-radius:6px; flex: 0 0 auto; }
.carousel-thumbs .thumb img { width: 110px; height: 70px; object-fit: cover; border-radius:6px; display:block; opacity:0.8; }
.carousel-thumbs .thumb.active img { outline: 3px solid var(--primary); opacity:1; }

.carousel-thumbs::-webkit-scrollbar { height: 8px; }
.carousel-thumbs::-webkit-scrollbar-thumb { background: rgba(0,0,0,0.08); border-radius: 8px; }

/* Gallery modal overrides */
#galleryModal .modal-content {
  background: transparent;
  max-width: 95%;
  width: 95%;
  padding: 0;
  box-shadow: none;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

#galleryModal img#galleryImage {
  max-width: 90vw;
  max-height: 80vh;
  border-radius: 8px;
  box-shadow: 0 10px 40px rgba(0,0,0,0.6);
  display: block;
}

.gallery-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0,0,0,0.6);
  color: white;
  border: none;
  width: 48px;
  height: 64px;
  font-size: 28px;
  border-radius: 6px;
  cursor: pointer;
  z-index: 3000;
}

.gallery-nav.prev { left: 8px; }
.gallery-nav.next { right: 8px; }

.gallery-counter {
  position: absolute;
  bottom: 8px;
  left: 50%;
  transform: translateX(-50%);
  color: rgba(255,255,255,0.95);
  background: rgba(0,0,0,0.45);
  padding: 6px 10px;
  border-radius: 8px;
  font-weight: 600;
  z-index: 3000;
}

.portfolio-item {
  position: relative;
  height: 340px;
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.12);
  cursor: pointer;
  transition: transform 0.35s ease, box-shadow 0.35s ease;
}

.portfolio-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.portfolio-item:hover img {
  transform: scale(1.08) translateY(-4px);
}

.portfolio-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--light);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.portfolio-item:hover .portfolio-overlay {
  opacity: 1;
}

.portfolio-text {
  text-align: center;
}

.portfolio-text h3 {
  font-size: 24px;
  margin-bottom: 10px;
}

@media (max-width: 768px) {
  .portfolio-grid { width: calc(100% - 24px); margin-left: 12px; margin-right: 12px; gap: 18px; }
  .portfolio-item { height: 260px; border-radius: 10px; }
  .portfolio-text h3 { font-size: 20px; }
}

/* TESTIMONIALS */
.testimonials {
  padding: 60px 20px;
  background: var(--light);
}

.testimonials-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
  margin-top: 40px;
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
}

.testimonial-card {
  padding: 30px;
  background: var(--gray);
  border-radius: 12px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
}

.testimonial-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

.stars {
  color: #FFD700;
  font-size: 18px;
  margin-bottom: 15px;
}

.testimonial-card p {
  font-style: italic;
  margin-bottom: 15px;
  color: #666;
}

.testimonial-author {
  font-weight: 600;
  color: var(--secondary);
}

/* CONTACT BOX */
.contact-box {
  background: var(--gray);
  padding: 40px;
  border-radius: 12px;
  margin: 40px 0;
  border-left: 4px solid var(--primary);
}

.contact-box p {
  font-size: 18px;
  margin: 15px 0;
}

/* CONTACT FORM */
.contact-form {
  max-width: 600px;
  margin: 30px 0;
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
  color: var(--secondary);
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 12px;
  border: 2px solid var(--border);
  border-radius: 6px;
  font-family: inherit;
  font-size: 14px;
  transition: all 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(255, 107, 53, 0.1);
}

.form-group textarea {
  resize: vertical;
  min-height: 120px;
}

.form-group button {
  width: 100%;
  padding: 14px;
  background: var(--primary);
  color: var(--light);
  border: none;
  border-radius: 6px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.form-group button:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(255, 107, 53, 0.4);
}

/* FOOTER */
.footer {
  background: linear-gradient(135deg, var(--secondary) 0%, var(--accent) 100%);
  color: var(--light);
  padding: 60px 20px 20px;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 40px;
  max-width: 1200px;
  margin: 0 auto 40px;
}

.footer h3 {
  margin-bottom: 20px;
  font-size: 20px;
}

.footer p {
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: 10px;
  line-height: 1.8;
}

.footer-bottom {
  text-align: center;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.2);
  color: rgba(255, 255, 255, 0.8);
}

/* BACK TO TOP */
.back-to-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 50px;
  height: 50px;
  background: var(--primary);
  color: var(--light);
  border: none;
  border-radius: 50%;
  font-size: 24px;
  cursor: pointer;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 500;
  box-shadow: 0 4px 15px rgba(255, 107, 53, 0.3);
  transition: all 0.3s ease;
}

.back-to-top.show {
  display: flex;
}

.back-to-top:hover {
  transform: translateY(-5px);
  box-shadow: 0 6px 25px rgba(255, 107, 53, 0.5);
}

/* MODAL */
.modal {
  display: none;
  position: fixed;
  z-index: 2000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  animation: fadeInUp 0.3s ease;
}

.modal.open {
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-content {
  background: var(--light);
  padding: 40px;
  border-radius: 12px;
  max-width: 500px;
  width: 90%;
  position: relative;
  animation: slideInUp 0.3s ease;
}

@keyframes slideInUp {
  from {
    opacity: 0;
    transform: translateY(50px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.close-btn {
  position: absolute;
  top: 15px;
  right: 20px;
  font-size: 28px;
  font-weight: bold;
  cursor: pointer;
  color: #999;
  background: none;
  border: none;
  transition: color 0.3s;
}

.close-btn:hover {
  color: var(--primary);
}

/* RESPONSIVE */
@media (min-width: 768px) {
  .phone {
    display: block;
  }

  .nav-desktop {
    display: flex;
  }

  .hamburger {
    display: none;
  }

  .mobile-menu {
    display: none;
  }

  .section {
    padding: 80px 20px;
  }

  .section h2 {
    font-size: 42px;
  }

  .services {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* SCROLL ANIMATION */
.fade-in {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.6s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* LOADER */
.loader {
  display: none;
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 9999;
}

.loader.show {
  display: block;
}

.spinner {
  border: 4px solid var(--gray);
  border-top: 4px solid var(--primary);
  border-radius: 50%;
  width: 40px;
  height: 40px;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* New gallery styles (static gallery + lightbox) */
.gallery-static { max-width: 1100px; margin: 0 auto; }
.gallery-main { display:flex; align-items:center; justify-content:center; margin-bottom:12px; }
.gallery-main img { width:100%; max-width:900px; max-height:60vh; object-fit:cover; border-radius:8px; box-shadow: 0 12px 40px rgba(0,0,0,0.35); cursor: pointer; }
.gallery-thumbs {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding: 8px 6px;
  -webkit-overflow-scrolling: touch;
  scroll-behavior: smooth;
  touch-action: pan-x;
  -ms-touch-action: pan-x;
}
.gallery-thumbs .thumb {
  border: none;
  background: transparent;
  padding: 0;
  cursor: pointer;
  border-radius: 6px;
  flex: 0 0 auto;
  -webkit-user-select: none;
  user-select: none;
}
.gallery-thumbs .thumb img { width:110px; height:70px; object-fit: cover; border-radius:6px; display:block; opacity:0.85; }
.gallery-thumbs .thumb.active img { outline: 3px solid var(--primary); opacity:1; }
.gallery-thumbs::-webkit-scrollbar { height:8px; }
.gallery-thumbs::-webkit-scrollbar-thumb { background: rgba(0,0,0,0.08); border-radius:8px; }

/* :target lightbox modals inside .lightbox-modals */
.lightbox-modals .lb { display:none; position:fixed; z-index:2500; left:0; top:0; width:100%; height:100%; background: rgba(0,0,0,0.85); align-items:center; justify-content:center; }
.lightbox-modals .lb:target { display:flex; }
.lightbox-modals .lb img { max-width: 90vw; max-height: 85vh; border-radius:8px; box-shadow: 0 12px 40px rgba(0,0,0,0.6); }
.lightbox-modals .lb-close { position:absolute; top:24px; right:24px; color:#fff; font-size:36px; text-decoration:none; }

@media (max-width: 600px){
  .gallery-thumbs .thumb img { width:72px; height:52px; }
  .gallery-main img { max-height: 45vh; }
  .gallery-thumbs {
    -webkit-overflow-scrolling: touch;
    scroll-behavior: smooth;
    touch-action: pan-x;
    -ms-touch-action: pan-x;
  }
}

/* Additional mobile tweaks for gallery/modal */
@media (max-width: 480px) {
  .gallery-static { padding: 0 10px; }
  .gallery-main { margin-bottom: 8px; }
  .gallery-main img { width: 100%; max-width: 100%; height: auto; max-height: calc(100vh - 160px); border-radius: 6px; }
  .gallery-thumbs {
    gap: 8px;
    padding: 6px 4px;
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scroll-behavior: smooth;
    touch-action: pan-x;
    -ms-touch-action: pan-x;
  }
  .gallery-thumbs .thumb { flex: 0 0 22%; }
  .gallery-thumbs .thumb img { width: 100%; height: 56px; object-fit: cover; }

  /* Make modal take most of the viewport on small screens */
  #galleryModal .modal-content { background: transparent; padding: 0; width: 100%; max-width: 100%; }
  #galleryModal img#galleryImage { max-width: 100vw; max-height: calc(100vh - 120px); border-radius: 6px; }
  .gallery-nav { width: 40px; height: 52px; font-size: 22px; }
  .gallery-counter { font-size: 13px; padding: 4px 8px; bottom: 12px; }

  /* Reduce hero height for small devices */
  .hero { height: 55vh; }
  .hero h1 { font-size: clamp(24px, 8vw, 40px); }
  .hero p { font-size: 14px; }
}
