/* ===== Base Styles ===== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: Poppins, sans-serif;
}

html {
  overflow-x: hidden;
  -webkit-text-size-adjust: 100%;
}

body {
  cursor: auto;
  background: #ffffff;
  color: #333;
  overflow-x: hidden;
  padding-left: env(safe-area-inset-left);
  padding-right: env(safe-area-inset-right);
}

body.nav-locked {
  overflow: hidden;
}

img,
video {
  max-width: 100%;
  height: auto;
}

/* ===== Custom Cursor (pointer devices only) ===== */
@media (hover: hover) and (pointer: fine) {
  body.has-custom-cursor {
    cursor: none;
  }
}

.cursor-small {
  position: fixed;
  width: 8px;
  height: 8px;
  background: #00008B;
  border-radius: 50%;
  pointer-events: none;
  z-index: 9999;
  transform: translate(-50%, -50%);
  transition: background 0.2s ease, transform 0.1s ease;
  box-shadow: 0 0 8px #00ffff;
}

.cursor-large {
  position: fixed;
  width: 30px;
  height: 30px;
  border: 2px solid #00008B;
  border-radius: 50%;
  pointer-events: none;
  z-index: 9998;
  transform: translate(-50%, -50%);
  transition: width 0.3s ease, height 0.3s ease, border-color 0.3s ease;
  box-shadow: 0 0 12px #00ffff;
}

a:hover ~ .cursor-large,
.btn:hover ~ .cursor-large {
  border-color: #00ffff;
  width: 45px;
  height: 45px;
  box-shadow: 0 0 20px #00ffff;
}

a:hover ~ .cursor-small,
.btn:hover ~ .cursor-small {
  background: #00ffff;
  box-shadow: 0 0 10px #00ffff;
}

.logo{
  font-size: 25px;
  color: #000066;
}

/* ===== NAVBAR ===== */
.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: max(16px, env(safe-area-inset-top)) max(8%, env(safe-area-inset-right)) 16px max(8%, env(safe-area-inset-left));
  background: white;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
  transition: 0.3s;
  position: relative;
  z-index: 1000;
}

.navbar-scrolled {
  background: #00008B;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
}

.navbar-scrolled .logo,
.navbar-scrolled .nav-links a {
  color: #fff;
}

.navbar-scrolled .nav-toggle-bar {
  background: #fff;
}

.nav-toggle {
  display: none;
  position: relative;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 10px;
  border: none;
  background: transparent;
  cursor: pointer;
  flex-shrink: 0;
  z-index: 2;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

.nav-toggle-bar {
  display: block;
  width: 24px;
  height: 2px;
  background: #333;
  border-radius: 2px;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.navbar.nav-open .nav-toggle-bar:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.navbar.nav-open .nav-toggle-bar:nth-child(2) {
  opacity: 0;
}

.navbar.nav-open .nav-toggle-bar:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 30px;
}

.nav-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  z-index: 999;
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

.nav-overlay.is-visible {
  opacity: 1;
  pointer-events: auto;
}

.nav-links {
  list-style: none;
  display: flex;
  gap: 30px;
  margin: 0;
  padding: 0;
}

.nav-links a {
  text-decoration: none;
  color: #333;
  font-weight: 500;
  transition: 0.3s;
}

.nav-links a:hover {
  color: #00008B;
  border-bottom: 2px solid #00008B;
}

.navbar-scrolled .nav-links a:hover {
  color: #00ffff;
  border-bottom-color: #00ffff;
}

.nav-cta {
  white-space: nowrap;
}

/* ===== HERO ===== */
.hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 80px 8%;
  flex-wrap: wrap;
}
.hero-content { max-width: 500px; }
.hero h1 { font-size: clamp(1.75rem, 5vw, 2.8125rem); margin-bottom: 20px; }
.hero span { color: #00008B; }
.hero p { margin-bottom: 30px; }
.hero-buttons { display: flex; gap: 10px; }
.hero-image img { width: 500px; border-radius: 10px; max-width: 100%; }

/* ===== BUTTONS ===== */
.btn {
  padding: 12px 25px;
  border-radius: 6px;
  text-decoration: none;
  font-weight: 600;
  display: inline-block;
  transition: 0.3s;
}
.primary-btn {
  background: #00008B;
  color: white;
  border: none;
}

.btn .primary-btn :hover{
  background: #fff;
  color: #00008B;
}

.primary-btn:hover {
  background: #344986;
  transform: translateY(-2px);
}
.outline-btn {
  border: 1.7px solid #00008B;
}
.outline-btn:hover {
  background: #fff;
  color: #00008B;
}

/* Back to Top Button */
#back-to-top {
    position: fixed;
    bottom: 40px;
    right: 40px;
    background: #00ffff;
    color: #000033;
    border: none;
    padding: 15px 18px;
    border-radius: 50%;
    font-size: 1.2rem;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
    display: none; /* hidden by default */
    z-index: 9999;
    transition: all 0.3s ease;
}

#back-to-top:hover {
    background: #000033;
    color: #00ffff;
    transform: translateY(-3px);
}

/* ===== SERVICES ===== */
/* --- Services Elite Section --- */
.services-elite {
    padding: 100px 8%;
    background: #fcfdfe;
}

.section-header {
    text-align: center;
    margin-bottom: 60px;
}

.pre-title {
    color: #00008B;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-size: 0.8rem;
    display: block;
    margin-bottom: 10px;
}

.section-header h2 {
    font-size: clamp(1.75rem, 4vw, 3rem);
    color: #000033;
    font-weight: 800;
}

.section-header h2 span {
    color: #00008B;
}

.section-header p {
    max-width: 600px;
    margin: 15px auto;
    color: #666;
    line-height: 1.6;
}

/* --- Grid Layout --- */
.service-grid-v3 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
}

/* --- Card Design --- */
.service-card {
    background: #fff;
    padding: 50px 40px;
    border-radius: 24px;
    position: relative;
    border: 1px solid #f0f0f0;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.service-card:hover {
    transform: translateY(-12px);
    box-shadow: 0 40px 80px rgba(0, 0, 139, 0.08);
    border-color: #00008B;
}

.card-number {
    position: absolute;
    top: 30px;
    right: 40px;
    font-size: 3rem;
    font-weight: 900;
    color: rgba(0, 0, 139, 0.03); /* Subtle watermark effect */
}

.icon-box {
    width: 70px;
    height: 70px;
    background: #f4f7ff;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 25px;
    transition: 0.3s;
}

.icon-box img {
    width: 35px;
    height: 35px;
    object-fit: contain;
}

.service-card:hover .icon-box {
    background: #00008B;
}

.service-card:hover .icon-box img {
    filter: brightness(0) invert(1); /* Turns icon white on hover */
}

.service-card h3 {
    font-size: 1.5rem;
    margin-bottom: 15px;
    color: #000033;
}

.service-card p {
    color: #555;
    font-size: 0.95rem;
    line-height: 1.7;
    margin-bottom: 30px;
}

/* --- Highlighted Card (e.g. your Best Seller) --- */
.service-card.highlighted {
    background: linear-gradient(145deg, #ffffff, #f0f4ff);
    border: 1px solid #00008B;
}

/* --- Footer Link --- */
.learn-more {
    text-decoration: none;
    color: #00008B;
    font-weight: 700;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: 0.3s;
}

.learn-more i {
    transition: 0.3s;
}

.service-card:hover .learn-more i {
    transform: translateX(8px);
}

@media (max-width: 768px) {
    .section-header h2 { font-size: 2.2rem; }
    .service-grid-v3 { grid-template-columns: 1fr; }
}
/* ===== CTA SECTION ===== */
.cta {
  padding: 90px 8%;
  background: linear-gradient(135deg, #00008B, #02024f);
  text-align: center;
  color: white;
  position: relative;
  overflow: hidden;
}

.cta-container {
  max-width: 700px;
  margin: auto;
}

.cta h2 {
  font-size: clamp(1.5rem, 4vw, 2.375rem);
  margin-bottom: 20px;
}

.cta p {
  font-size: 17px;
  line-height: 1.7;
  margin-bottom: 35px;
  color: #dcdcff;
}

.cta-buttons {
  display: flex;
  justify-content: center;
  gap: 15px;
  flex-wrap: wrap;
}

/* Glow effect */
.cta::before,
.cta::after {
  content: "";
  position: absolute;
  width: 300px;
  height: 300px;
  background: #00ffff;
  filter: blur(120px);
  opacity: 0.25;
}

.cta::before {
  top: -50px;
  left: -50px;
}

.cta::after {
  bottom: -50px;
  right: -50px;
}

/* ===== PORTFOLIO ===== */
/* --- Refined Portfolio with Brand Colors --- */
.portfolio-refined {
    padding: 100px 8%;
    background: #f9faff; /* Light clean background */
}

.portfolio-grid-v4 {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 30px;
    margin-top: 50px;
    align-items: stretch;
}

/* Feature Card (The Big One) */
.work-feature-card {
    background: #fff;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 15px 40px rgba(0,0,139,0.05);
    border: 1px solid #eef0f7;
    display: flex;
    flex-direction: column;
}

.work-feature-card .work-img {
    height: 350px;
    position: relative;
}

.work-feature-card .work-img img {
    width: 100%; height: 100%; object-fit: cover;
}

.work-tag {
    position: absolute; top: 20px; left: 20px;
    background: #00008B; color: #fff;
    padding: 6px 15px; border-radius: 5px; font-size: 0.75rem; font-weight: 700;
}

.work-details { padding: 40px; }

.metric-row { display: flex; align-items: baseline; gap: 10px; margin-bottom: 15px; }
.big-number { font-size: 2.5rem; font-weight: 800; color: #00008B; }
.metric-label { color: #00ffff; font-weight: 700; text-transform: uppercase; font-size: 0.8rem; }

/* Side Grid (The 4 Small Ones) */
.work-side-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.side-card {
    background: #00008B; /* Your Brand Navy */
    border-radius: 15px;
    padding: 25px;
    display: flex;
    align-items: center;
    transition: 0.3s ease;
    position: relative;
}

.side-card:hover {
    transform: translateY(-5px);
    background: #000066;
}

.side-tag {
    color: #00ffff; /* Your Brand Cyan */
    font-size: 0.65rem;
    font-weight: 700;
    text-transform: uppercase;
    display: block;
    margin-bottom: 8px;
}

.side-card h3 { color: #fff; font-size: 1.1rem; margin-bottom: 5px; }
.side-metric { color: rgba(255,255,255,0.7); font-size: 0.85rem; font-weight: 600; }

.icon-link {
    position: absolute; bottom: 20px; right: 20px;
    color: #00ffff; font-size: 1rem;
}

/* Aligned Text Styles */
.view-link {
    color: #00008B; text-decoration: none; font-weight: 700;
    display: inline-flex; align-items: center; gap: 10px; margin-top: 20px;
}

/* Mobile Alignment */
@media (max-width: 1100px) {
    .portfolio-grid-v4 { grid-template-columns: 1fr; }
}

@media (max-width: 600px) {
    .work-side-grid { grid-template-columns: 1fr; }
}

/* ===== OUR WORK ===== */
.portfolio-work-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit,minmax(250px,1fr));
  gap: 25px;
  margin-top: 50px;
}

/* WORK CARDS */
.work-card {
  position: relative;
  overflow: hidden;
  border-radius: 12px;
  box-shadow: 0 8px 25px rgba(0,0,0,0.08);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.work-card img {
  width: 100%;
  display: block;
  transition: transform 0.5s ease;
}

/* Overlay text always visible */
.work-overlay {
  position: absolute;
  bottom: 20px; /* start near bottom */
  left: 0;
  width: 100%;
  color: #fff;
  text-align: center;
  padding: 20px;
  transition: transform 0.5s ease;
  background: rgba(0, 0, 0, 0.774); /* slightly transparent over image */
  border-radius: 0 0 12px 12px;
}

/* Slide the text block up when hover */
.work-card:hover .work-overlay {
  transform: translateY(-100%); /* moves the text off the top */
}

.work-overlay h3 {
  margin-bottom: 8px;
  font-size: 18px;
  color: #00ffff;
}

.work-overlay p {
  font-size: 14px;
  line-height: 1.4;
  opacity: 0.95;
}

/* Card hover effects */
.work-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 40px rgba(0,255,255,0.3);
}

@media (hover: none), (pointer: coarse) {
  .work-card:hover .work-overlay {
    transform: none;
  }
}

/* ===== CONTACT ===== */
.contact { padding: 80px 8%; text-align: center; }
.contact-form { max-width: 500px; margin: auto; display: flex; flex-direction: column; gap: 20px; }
.contact-form input,
.contact-form textarea { padding: 12px; border-radius: 6px; border: 1px solid #ccc; width: 100%; }

/* ===== FOOTER ===== */
footer { text-align: center;
  padding: 30px;
  background:#00008B;
  color: white;
}


/* CONTACT SECTION */
/* ===== NEW CONTACT SECTION ===== */
.contact {
    padding: 100px 8%;
    background: #ffffff; /* Clean White Background */
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    max-width: 1200px;
    margin: auto;
}

.contact-info-side {
    text-align: left;
}

.contact-info-side h2 {
    font-size: clamp(1.75rem, 4vw, 2.625rem);
    color: #333;
    margin-bottom: 20px;
}

.contact-info-side h2 span {
    color: #00008B;
}

.contact-info-side p {
    color: #666;
    margin-bottom: 40px;
}

/* Social Icons - Fixed to follow #00008B pattern */
.social-icons-wrapper {
    display: flex;
    gap: 15px;
    margin-bottom: 40px;
}

.social-item {
    width: 50px;
    height: 50px;
    background: #fff;
    border: 2px solid #00008B; /* Your Brand Color */
    color: #00008B;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-size: 20px;
    text-decoration: none;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

/* Better Hover: Fills with color and pops up */
.social-item:hover {
    background: #00008B;
    color: #fff;
    transform: translateY(-10px);
    box-shadow: 0 10px 20px rgba(0, 0, 139, 0.3);
}

.direct-contact p {
    margin-bottom: 10px;
    font-weight: 600;
}

.direct-contact a {
    color: #00008B;
    text-decoration: none;
}

/* Form Styling */
.contact-form-side {
    background: #f7f9ff;
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
}

.input-group {
    margin-bottom: 20px;
}

.contact-form input, 
.contact-form textarea {
    border: 1.5px solid #e0e0e0;
    background: #fff;
    transition: 0.3s;
}

.contact-form input:focus, 
.contact-form textarea:focus {
    outline: none;
    border-color: #00008B;
    box-shadow: 0 0 10px rgba(0, 0, 139, 0.1);
}

/* RESPONSIVE */
@media (max-width: 992px) {
    .contact-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }
    .contact-info-side { text-align: center; }
    .social-icons-wrapper { justify-content: center; }
}
/* ===== BACK TO TOP ===== */
.back-to-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  background: #00008B;
  color: white;
  border: none;
  padding: 12px 18px;
  border-radius: 50%;
  cursor: pointer;
  display: none;        /* starts hidden, will show on scroll */
  font-size: 20px;
  z-index: 10000;       /* make sure it's on top of everything */
  transition: opacity 0.3s ease;
}

.back-to-top.show {
  display: block;
  opacity: 1;
}
/* ===== RESPONSIVE ===== */
@media (max-width: 992px) {
  .nav-toggle {
    display: flex;
  }

  .nav-menu {
    position: fixed;
    top: 0;
    right: 0;
    width: min(320px, 88vw);
    height: 100dvh;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: max(88px, calc(env(safe-area-inset-top) + 72px)) 28px 28px;
    padding-bottom: max(28px, env(safe-area-inset-bottom));
    background: #fff;
    box-shadow: -8px 0 30px rgba(0, 0, 0, 0.12);
    transform: translateX(100%);
    visibility: hidden;
    transition: transform 0.3s ease, visibility 0.3s ease;
    z-index: 999;
    overflow-y: auto;
    pointer-events: none;
  }

  .navbar.nav-open .nav-menu {
    transform: translateX(0);
    visibility: visible;
    pointer-events: auto;
  }

  .nav-overlay {
    display: block;
    z-index: 998;
  }

  .nav-links {
    flex-direction: column;
    gap: 0;
    width: 100%;
  }

  .nav-links li {
    border-bottom: 1px solid #eee;
  }

  .nav-links a {
    display: block;
    padding: 16px 0;
    font-size: 1.05rem;
    border-bottom: none;
  }

  .navbar .btn.primary-btn,
  .navbar .bts,
  .nav-cta {
    margin-top: 20px;
    text-align: center;
    width: 100%;
  }

  .hero {
    flex-direction: column;
    padding: 60px 5%;
    text-align: center;
  }

  .hero-buttons {
    flex-direction: column;
    gap: 15px;
    align-items: center;
  }

  .hero-image {
    width: 100%;
    display: flex;
    justify-content: center;
  }

  .hero-image img {
    width: min(100%, 420px);
  }
}

@media (max-width: 600px) {
  .hero p {
    font-size: 16px;
  }

  .services,
  .services-elite,
  .portfolio,
  .portfolio-refined,
  .contact,
  .cta {
    padding: 60px 5%;
  }

  .service-grid,
  .portfolio-grid,
  .service-grid-v3 {
    grid-template-columns: 1fr;
  }

  .work-feature-card .work-img {
    height: clamp(200px, 40vw, 350px);
  }

  footer {
    padding: 20px 5%;
    font-size: 14px;
  }

  #back-to-top,
  .back-to-top {
    bottom: max(20px, env(safe-area-inset-bottom));
    right: max(20px, env(safe-area-inset-right));
  }
}

@media (max-width: 400px) {
  .btn,
  .bts {
    padding: 10px 18px;
    font-size: 14px;
  }
}

@media (orientation: landscape) and (max-height: 500px) {
  .hero {
    padding-top: 40px;
    padding-bottom: 40px;
  }

  .nav-menu {
    padding-top: max(64px, env(safe-area-inset-top));
  }
}

@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;
  }
}