/* ------ MOBILE: Fullscreen 3D background behind the whole page( home,about,services) ------ */
@media (max-width: 900px){

  /* hero stacks normally */
  .hero {
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding: 100px 16px 24px;
    min-height: auto;
    gap: 20px;
    background: transparent;   /* let 3D show through */
    position: relative;
    z-index: 2;
    padding: 250px 70px;
  }
  .hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(0,0,0,0.6), rgba(0,0,0,0.4));
  z-index: 2;
}
.hero-content {
  position: relative;
  z-index: 3;
}


  .hero--with-fixed-3d { padding-right: 0; }

  /* turn the Spline pane into a full-screen background layer */
  .hero-3d {
    position: fixed;      /* fixed so it stays behind ALL sections */
    inset: 0;             /* top:0; right:0; bottom:0; left:0 */
    width: 100vw;
    height: 100vh;
    z-index: 0;           /* below all content */
    pointer-events: none; /* don't block scroll/taps */
    display: block;
  }
  .hero-3d iframe {
    width: 100%;
    height: 100%;
    border: 0;
    display: block;
  }

  /* If you also used a global fixed-3d container anywhere, make it full-screen too */
  .fixed-3d {
    position: fixed;
    inset: 0;
    width: 100vw;
    height: 100vh;
    z-index: 0;
    pointer-events: none;
    background: transparent;
  }
  .fixed-3d iframe { width:100%; height:100%; border:0; }

  /* services grid responsive */
  .ws-services { padding: 56px 16px 72px; }
  .ws-grid {
    grid-template-columns: 1fr;
    gap: 18px;
  }
  .ws-card { padding: 22px; }
  .ws-icon { width:46px; height:46px; border-radius:12px; }
  .ws-card-title { font-size: 17px; }
  .ws-card-desc { font-size: 14px; }


  /* Hero Buttons Responsive Fix */
  .buttons {
    flex-direction: column;
    align-items: center;
    gap: 12px;
    width: 100%;
  }

  .btn {
    width: 80%;
    max-width: 280px;
    text-align: center;
    padding: 10px 0;
    font-size: 1rem;
  }

  .btn.primary {
    background: linear-gradient(90deg, #0074ac, #9cfced);
    color: #000;
  }

  .btn.outline {
    border: 1px solid #9cfced;
    color: #9cfced;
  }

  .btn.outline:hover {
    background: #9cfced;
    color: #000;
  }
}


/* Optional: subtle readability veil only under Services on mobile */
@media (max-width: 900px){
  .ws-services.ws-glass::before{
    content:"";
    position:absolute; inset:0;
    background: linear-gradient(to bottom, rgba(0,0,0,.25), rgba(0,0,0,.15));
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    pointer-events:none;
    z-index: 1;
  }
  .ws-services.ws-glass > * { position: relative; z-index: 2; }
}




/* === NAVBAR TEXT & BUTTON SIZE FIX FOR DESKTOP (above 900px) === */
@media (min-width: 901px) {

  /* links in the navbar */
  #site-header nav a {
    font-size: 0.95rem;       /* smaller text */
    padding: 8px 0;           /* balanced spacing */
    margin-left: 22px;        /* closer spacing between links */
  }

  /* contact button */
  #site-header .contact-btn {
    padding: 8px 18px;
    font-size: 0.95rem;
    border-radius: 25px;
    background: linear-gradient(90deg, #3eb7d2, #55ee9f);
    color: #000;
    font-weight: 600;
  }

  /* logo spacing refinement */
  #site-header .logo {
    font-size: 1.2rem;
    font-weight: 700;
  }
}



/* ===== Responsive business sector ===== */
@media (max-width: 1024px){
  .fw-grid{ grid-template-columns: repeat(2, minmax(0,1fr)); }
}
@media (max-width: 640px){
  .fw-section{ padding: 64px 16px 80px; }
  .fw-grid{ grid-template-columns: 1fr; gap: 18px; }
}

/*footer*/
@media (max-width: 600px) {
  .footer__bottom {
    flex-direction: column;
    text-align: center;
    gap: 8px;
  }
}



@media (max-width: 900px) {
  /* Global layout fix */
  body, html {
    overflow-x: hidden;
    overflow-y: auto;
  }

  section {
    display: block !important;
    opacity: 1 !important;
    visibility: visible !important;
    height: auto !important;
    overflow: visible !important;
    padding: 60px 20px;
  }

  /* Navbar */
  nav ul {
    flex-direction: column;
    position: absolute;
    top: 60px;
    right: 0;
    width: 100%;
    background: #4D148C;
    display: none;
  }

  nav ul.active {
    display: flex;
  }

  /* Hero Section */
  .hero {
    flex-direction: column;
    text-align: center;
  }

  .hero img {
    width: 90%;
    margin: 20px auto 0;
  }

  /* Containers */
  .service-container,
  .sector-container,
  .team-container,
  .media-container,
  .contact-container {
    flex-direction: column;
    align-items: center;
    justify-content: center;
    display: flex !important;
    opacity: 1 !important;
    visibility: visible !important;
  }

  /* Cards */
  .service-card,
  .sector-card,
  .team-member {
    width: 90%;
    max-width: 300px;
    margin: 20px auto;
  }

  /* Contact form fix */
  .contact form {
    width: 100%;
  }

  
}

/* === SERVICES CARD SIZE FIX (645px–900px) === */
@media (min-width: 645px) and (max-width: 900px) {
  .ws-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
    padding: 0 20px;
  }

  .ws-card {
    padding: 20px 18px;
    border-radius: 14px;
    max-width: 100%;
    height: auto;
  }

  .ws-card-title {
    font-size: 1.05rem;
    margin-bottom: 8px;
  }

  .ws-card-desc {
    font-size: 0.9rem;
    line-height: 1.5;
  }

  .ws-icon {
    width: 50px;
    height: 50px;
    margin-bottom: 12px;
  }

  .ws-card svg {
    width: 100%;
    height: 100%;
  }

  .ws-head {
    text-align: center;
    margin-bottom: 40px;
  }

  .ws-sub {
    font-size: 1rem;
    line-height: 1.5;
    width: 90%;
    margin: 0 auto;
  }
}



/* === CONTACT SECTION MAP RESPONSIVE FIX === */
@media (max-width: 450px) {
  .contact__grid {
    display: flex;
    flex-direction: column;
    gap: 32px;
  }

  .contact-aside {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  .cards {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 18px;
  }

  .map-wrap {
    width: 100%;
    height: 150px;
    margin-top: 16px;
    border-radius: 10px;
    overflow: hidden;
  }

  .map-wrap iframe {
    width: 100%;
    height: 100%;
    border: none;
    display: block;
  }
}



/* === FOOTER RESPONSIVE FIX === */
@media (max-width: 900px) {
  .footer__content {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 32px;
    padding: 40px 20px;
  }

  .footer__col {
    width: 100%;
    max-width: 400px;
  }

  .footer-logo {
    width: 140px;
    height: auto;
    margin-bottom: 16px;
  }

  .footer__col.about p {
    font-size: 0.95rem;
    line-height: 1.6;
  }

  .social {
    margin-top: 14px;
    display: flex;
    justify-content: center;
    gap: 10px;
  }

  .footer__col.links ul,
  .footer__col.contact ul {
    list-style: none;
    padding: 0;
    margin: 0;
  }

  .footer__col.links ul li,
  .footer__col.contact ul li {
    margin-bottom: 8px;
  }

  .footer__col.links a,
  .footer__col.contact a {
    color: #9cfced;
    text-decoration: none;
    font-size: 0.95rem;
  }

  .footer__bottom {
    flex-direction: column;
    text-align: center;
    gap: 8px;
    padding: 20px 10px;
  }

  .footer__bottom p {
    font-size: 0.85rem;
  }
}


/* === FOOTER COMPANY INFO CENTER FIX (400px–900px) === */
@media (min-width: 400px) and (max-width: 900px) {
  .footer__content {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .footer__col.about {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    width: 100%;
    max-width: 600px;
    margin: 0 auto;
  }

  .footer__col.about p {
    text-align: center;
    margin: 0 auto;
    line-height: 1.6;
    font-size: 0.95rem;
    width: 90%;
  }

  .footer-logo {
    display: block;
    margin: 0 auto 16px;
    width: 140px;
    height: auto;
  }
}





@media (max-width: 400px) {

  /* Body padding & font adjustments */
  body, html {
    font-size: 14px;
  }

  section {
    padding: 40px 12px;
  }

  /* Header adjustments */
  header {
    padding: 15px 10px;
  }

  nav a {
    margin-left: 12px;
    font-size: 0.85rem;
  }

  .contact-btn {
    padding: 6px 14px;
    font-size: 0.85rem;
  }

  /* Hamburger */
  .hamburger {
    top: 15px;
    right: 10px;
  }

  /* Hero section */
  .hero-content h1 {
    font-size: 1.8rem;
    line-height: 1.2;
  }
  .hero-content p {
    font-size: 0.9rem;
  }
  .buttons .btn {
    padding: 10px 18px;
    font-size: 0.85rem;
  }

  /* Hero 3D iframe */
  .hero-3d {
    width: 90vw;
    height: 40vh;
    top: auto;
    bottom: 10px;
  }

  /* Services cards */
  .ws-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }
  .ws-card {
    padding: 16px;
  }
  .ws-card-title {
    font-size: 16px;
  }
  .ws-card-desc {
    font-size: 13px;
  }

  /* About section */
  .about-section h2 {
    font-size: 1.5rem;
  }
  .about-section p {
    font-size: 0.9rem;
  }

  /* Contact section */
  .contact__grid {
    flex-direction: column;
  }
  .contact-form, .contact-aside {
    width: 100%;
  }
  .contact-aside .map-wrap iframe {
    height: 200px;
  }
  .contact-form label span {
    font-size: 0.8rem;
  }
  .contact-form input, 
  .contact-form textarea {
    font-size: 0.85rem;
  }

  /* Footer */
  .footer__content {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }
  .footer__col {
    margin-bottom: 20px;
  }
  .footer__bottom {
    flex-direction: column;
    gap: 5px;
    font-size: 0.8rem;
  }

  /* Buttons globally */
  .btn {
    padding: 8px 14px;
    font-size: 0.85rem;
  }

  /* Animated line */
  .animated-line {
    height: 2px;
  }
}


@media (max-width: 400px) {
  .hero {
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding: 180px 12px 40px; /* top padding for content */
    min-height: 100vh;
    position: relative;
    z-index: 2;
  }

  .hero-3d {
    position: fixed;   /* keep it fixed behind the content */
    top: 0;            /* start at top of viewport */
    left: 0;
    width: 100vw;
    height: 100vh;     /* full screen */
    z-index: 0;        /* behind hero content */
    pointer-events: none;
  }

  .hero-3d iframe {
    width: 100%;
    height: 100%;
    border: 0;
    display: block;
  }

  .hero-content {
    position: relative;
    z-index: 2;
    text-align: left;               /* keep text aligned nicely */
    transform: translateX(10px);    /* move slightly to the right */
  }

  /* Adjust buttons to match text alignment */
  .buttons {
    flex-direction: column;
    gap: 10px;
    margin-top: 20px;
    align-items: flex-start;        /* buttons aligned with text */
  }

  .buttons .btn {
    width: auto;                    /* natural button width */
    font-size: 0.85rem;
    padding: 10px 14px;
  }
}









/* Small phones extra squeeze */
@media (max-width: 450px){
  :root{
    --sp-sec-y: 28px;
    --sp-stack: 10px;
    --gap-grid: 12px;
    --card-pad: 14px;
  }
  .map-wrap{ height: 220px !important; }
}

/* XS phones */
@media (max-width: 400px){
  :root{
    --sp-sec-y: 24px;
    --sp-stack: 8px;
  }
  .hero{ padding: 100px 12px 20px !important; }
  .about-section h2{ font-size: 1.45rem !important; }
  .about-section p{ font-size: .95rem !important; }
  .ws-card{ padding: 14px !important; }
}






/* === TEAM CARD COMPACT FIX (≤900px) === */
@media (max-width: 900px) {
  /* grid tighter */
  .fw-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px !important;
  }

  /* smaller cards */
  .team-member,
  .team-card {
    padding: 10px 12px !important;
    border-radius: 10px !important;
    max-width: 100% !important;
    box-shadow: 0 4px 14px rgba(0,0,0,.25);
  }

  /* avatar smaller */
  .team-member img,
  .team-card img,
  .team-member .avatar,
  .team-card .avatar {
    width: 50px !important;
    height: 50px !important;
    border-radius: 50%;
    object-fit: cover;
    margin-bottom: 8px;
  }

  /* text smaller */
  .team-member h3,
  .team-card h3,
  .team-member .name,
  .team-card .name {
    font-size: 0.9rem !important;
    margin-bottom: 4px !important;
    line-height: 1.2;
  }

  .team-member p,
  .team-card p,
  .team-member .role,
  .team-card .role {
    font-size: 0.8rem !important;
    line-height: 1.3 !important;
    color: #b7bcc5;
  }

  /* internal spacing tighter */
  .team-member :where(* + *),
  .team-card :where(* + *) {
    margin-top: 6px !important;
  }
}

/* === Extra-small phones (≤640px) === */
@media (max-width: 640px) {
  .fw-grid {
    grid-template-columns: 1fr !important;
    gap: 8px !important;
  }

  .team-member,
  .team-card {
    padding: 8px 10px !important;
  }

  .team-member img,
  .team-card img {
    width: 44px !important;
    height: 44px !important;
  }

  .team-member h3,
  .team-card h3 {
    font-size: 0.85rem !important;
  }

  .team-member p,
  .team-card p {
    font-size: 0.75rem !important;
  }
}




/* === TEAM BOX WIDTH REDUCED (≤900px) === */
@media (max-width: 900px) {
  /* grid keeps 2 columns, but each card narrower */
  .fw-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 260px)); /* each card max ~260px */
    justify-content: center;
    gap: 12px !important;
  }

  .team-member,
  .team-card {
    width: 100%;
    max-width: 240px !important;  /* ⬅️ reduce width */
    margin: 0 auto;
    padding: 12px !important;
    border-radius: 10px;
    box-shadow: 0 4px 14px rgba(0,0,0,.25);
  }

  /* smaller avatar */
  .team-member img,
  .team-card img,
  .team-member .avatar,
  .team-card .avatar {
    width: 48px !important;
    height: 48px !important;
    border-radius: 50%;
    object-fit: cover;
    margin-bottom: 6px;
  }

  /* text smaller */
  .team-member h3,
  .team-card h3,
  .team-member .name,
  .team-card .name {
    font-size: 0.9rem !important;
    margin-bottom: 3px !important;
    line-height: 1.2;
  }

  .team-member p,
  .team-card p,
  .team-member .role,
  .team-card .role {
    font-size: 0.8rem !important;
    line-height: 1.3 !important;
    color: #b7bcc5;
  }

  /* tighter internal spacing */
  .team-member :where(* + *),
  .team-card :where(* + *) {
    margin-top: 5px !important;
  }
}

/* === EXTRA SMALL PHONES (≤640px) === */
@media (max-width: 640px) {
  .fw-grid {
    grid-template-columns: 1fr !important;
    justify-content: center;
    gap: 10px !important;
  }

  .team-member,
  .team-card {
    max-width: 220px !important;  /* even narrower */
    padding: 10px !important;
  }

  .team-member img,
  .team-card img {
    width: 44px !important;
    height: 44px !important;
  }

  .team-member h3,
  .team-card h3 {
    font-size: 0.85rem !important;
  }

  .team-member p,
  .team-card p {
    font-size: 0.75rem !important;
  }
}






/* === Extra-small phones (≤640px) === */
@media (max-width: 640px){
  .fw-grid{
  
    grid-template-columns: 1fr !important;     /* single column on small phones */
    gap: 10px !important;
   
  }
  
}





/* ===================== Buttons & Navbar Links ===================== */

/* Desktop (901px+) */
@media (min-width: 901px){
  nav a {
    font-size: 0.95rem;
    margin-left: 20px;
    padding: 6px 0;
  }

  .contact-btn, .btn {
    font-size: 0.95rem;
    padding: 8px 18px;
    border-radius: 25px;
  }
}

/* Tablets & smaller laptops (645px–900px) */
@media (max-width: 900px){
  nav a {
    font-size: 0.9rem;
    margin-left: 16px;
  }

  .contact-btn, .btn {
    font-size: 0.9rem;
    padding: 8px 16px;
    width: auto;  /* avoid full-width unless necessary */
  }
}

/* Mobile phones (≤640px) */
@media (max-width: 640px){
  nav a {
    font-size: 0.85rem;
    margin-left: 12px;
  }

  .contact-btn, .btn {
    font-size: 0.85rem;
    padding: 6px 14px;
    width: auto;
  }

  /* Hero buttons stacked nicely */
  .buttons {
    flex-direction: column;
    gap: 10px;
    align-items: center;
  }
}


/* Responsive Design */

/* Mobile (up to 600px) */


@media (max-width: 600px) {
  .about-section {
    padding: 40px 15px;
  }

  .about-card {
    padding: 25px 20px;
  }

  .about-title {
    font-size: 1.8rem;
  }

  .about-text,
  .about-sub {
    font-size: 0.95rem;
    text-align: left;
  }

  .about-head p {
    font-size: 0.9rem;
  }

  .animated-line {
    width: 120px;
    height: 2px;
  }
}
@media (max-width: 601px){
  .about-text,
  .about-sub {
    font-size: 1rem;
    text-align: center;
   
  }
}

/* Tablet (601px–1024px) */
@media (min-width: 601px) and (max-width: 1024px) {
  .about-section {
    padding: 80px 30px;
  }

  .about-card {
    padding: 40px;
  }

  .about-title {
    font-size: 2.2rem;
  }

  .about-text,
  .about-sub {
    font-size: 1rem;
    text-align: center;
  }
}

/* Laptop & small desktop (1025px–1440px) */
@media (min-width: 1025px) and (max-width: 1440px) {
  .about-card {
    max-width: 1000px;
    padding: 50px;
  }

  .about-title {
    font-size: 2.5rem;
  }

  .about-text,
  .about-sub {
    font-size: 1.05rem;
    
  }
}

/* Ultra-wide screens (1441px+) */
@media (min-width: 1441px) {
  .about-card {
    max-width: 1300px;
  }
}



/* Business sector card scaling */
@media (min-width: 430px) and (max-width: 645px) {
   
  .fw-grid{
    transform: scale(0.9);         /* make slightly smaller */
    margin: 10px auto !important; 
    width: 80%; /* keep spacing even */
  }

  .fw-card img {
    width:                    /* shrink image slightly */
  }

  
}






/* ---------- Contact form: small-screen fixes ---------- */

/* Let form controls shrink properly */
.contact-form label { min-width: 0; }                 /* allow grid items to shrink */
.contact-form input[type="text"],
.contact-form input[type="email"],
.contact-form input[type="tel"],
.contact-form input[type="url"],
.contact-form textarea { width: 100%; min-width: 0; }

/* Tablet and below */
@media (max-width: 900px){
  .contact { padding: 100px 6% 70px; }
  .contact__grid { grid-template-columns: 1fr; }     /* stack form and aside */
}

/* Phone: collapse form rows to single column */
@media (max-width: 700px){
  .contact-form .row { grid-template-columns: 1fr; } /* Name / Email, Phone / Company become single column */
  .contact-form .row--middle { 
    grid-template-columns: 1fr; 
    gap: 12px;
  }
  .contact-form .agree { align-items: flex-start; }  /* checkbox text wraps nicely */
  .contact-form .agree span { line-height: 1.35; }
  .contact-form .btn.primary { width: 100%; }        /* full-width send button */
}

/* Extra small phones (your 460px case and smaller) */
@media (max-width: 460px){
  .contact { padding: 90px 16px 60px; }
  .contact__head p { font-size: .95rem; }
  .contact h2 { font-size: clamp(26px, 7vw, 36px); }
  .contact-form { padding: 14px; }
  .contact-form label span { font-size: .9rem; }
  .contact-form input,
  .contact-form textarea { padding: 10px 12px; }

  /* Cards and map spacing */
  .contact-aside .cards { gap: 10px; }
  .map-wrap { aspect-ratio: 16/12; }                 /* a bit taller for small screens */
}

/* Avoid any horizontal scroll from long strings */
.contact, .contact * { word-wrap: break-word; overflow-wrap: anywhere; }
