/* =============================================================
   BRS Technology — Design System
   Palette extracted from the logo: navy/blue base, cyan accent
   ============================================================= */
:root {
  --navy-900: #06122b;
  --navy-800: #0a1f47;
  --blue-700: #0b3d91;
  --blue-600: #0f56c4;
  --blue-500: #1671e0;
  --cyan-400: #29b6f6;
  --cyan-300: #5fd4ff;
  --white: #ffffff;
  --gray-100: #f4f7fb;
  --gray-200: #e6ecf4;
  --gray-500: #64748b;
  --gray-700: #334155;
  --radius: 10px;
  --shadow: 0 8px 24px rgba(10, 31, 71, 0.08);
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; overflow-x: hidden; }
body { font-family: var(--font); color: var(--gray-700); line-height: 1.65; background: var(--white); }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--blue-600); text-decoration: none; }
a:hover { color: var(--cyan-400); }
h1, h2, h3, h4 { color: var(--navy-800); line-height: 1.25; margin: 0 0 .5em; }
h1 { font-size: clamp(1.8rem, 4vw, 2.6rem); }
h2 { font-size: clamp(1.4rem, 3vw, 1.9rem); margin-top: 1.6em; }
p { margin: 0 0 1em; }
.container { max-width: 1180px; margin: 0 auto; padding: 0 20px; }
.section { padding: 48px 0; }
.section-alt { background: var(--gray-100); }
.section-dark { background: linear-gradient(135deg, var(--navy-900), var(--navy-800)); color: #cfe0ff; }
.section-dark h2, .section-dark h4 { color: var(--white); }
.lead { font-size: 1.1rem; color: var(--gray-700); }

/* Header */
.site-header { position: sticky; top: 0; z-index: 100; background: var(--white); box-shadow: 0 2px 10px rgba(0,0,0,.06); }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 12px 20px; }
.main-nav ul { list-style: none; display: flex; gap: 22px; margin: 0; padding: 0; }
.main-nav a { color: var(--navy-800); font-weight: 500; }
.has-mega { position: static; }
.mega-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  width: min(94vw, 1100px);
  max-height: 72vh;
  overflow-y: auto;
  background: var(--white);
  box-shadow: var(--shadow);
  border-radius: var(--radius);
  padding: 24px;
  gap: 20px 28px;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  z-index: 110;
}
.has-mega:hover .mega-menu { display: grid; }
.mega-col-title { font-weight: 700; color: var(--blue-700); display: block; margin-bottom: 8px; }
.mega-col { min-width: 0; }
.mega-col ul { list-style: none; padding: 0; margin: 0; display: block; }
.mega-col li { margin-bottom: 6px; font-size: .92rem; display: block; }
.header-cta { display: flex; gap: 10px; }
.mobile-toggle { display: none; background: none; border: none; font-size: 1.6rem; cursor: pointer; }

/* Buttons */
.btn { display: inline-block; padding: 12px 22px; border-radius: 999px; font-weight: 600; cursor: pointer; border: 2px solid transparent; }
.btn-primary { background: linear-gradient(135deg, var(--blue-600), var(--cyan-400)); color: var(--white); }
.btn-primary:hover { opacity: .92; color: var(--white); }
.btn-outline { border-color: var(--blue-600); color: var(--blue-600); background: transparent; }
.btn-outline-light { border-color: var(--white); color: var(--white); background: transparent; }
.btn-ghost { color: var(--navy-800); background: var(--gray-200); }

/* Hero */
.hero { background: radial-gradient(circle at 20% 20%, var(--blue-700), var(--navy-900) 60%); color: var(--white); padding: 90px 0; text-align: center; }
.hero h1 { color: var(--white); }
.hero-sub { max-width: 640px; margin: 0 auto 28px; font-size: 1.15rem; opacity: .92; }
.hero-cta { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

/* Row carousel — a single row of a fixed number of cards (6 on desktop,
   3 on tablet, 2 on phones) with horizontal scroll + snap and left/right
   nav buttons (paired with the .row-carousel-nav JS in main.js) for any
   items beyond that, instead of wrapping into extra rows. Used by the
   homepage "AMC & Maintenance" and "Industries We Serve" sections. */
.row-carousel { position: relative; margin-top: 20px; }
.row-carousel-track {
  display: flex; gap: 18px; overflow-x: auto; scroll-snap-type: x mandatory;
  scroll-behavior: smooth; padding-bottom: 4px; margin-top: 0;
  -ms-overflow-style: none; scrollbar-width: none;
}
.row-carousel-track::-webkit-scrollbar { display: none; }
.row-carousel-track > * { flex: 0 0 calc((100% - 18px * 5) / 6); min-width: 0; scroll-snap-align: start; }
.row-carousel-nav {
  position: absolute; top: 50%; transform: translateY(-50%); background: var(--white);
  color: var(--navy-800); border: 1px solid var(--gray-200); width: 38px; height: 38px;
  border-radius: 50%; cursor: pointer; font-size: 1.1rem; box-shadow: var(--shadow);
  z-index: 3; display: flex; align-items: center; justify-content: center;
}
.row-carousel-nav.prev { left: -18px; }
.row-carousel-nav.next { right: -18px; }
.row-carousel-nav:disabled { opacity: .3; cursor: default; }
@media (max-width: 1000px) {
  .row-carousel-track > * { flex: 0 0 calc((100% - 18px * 2) / 3); }
}
@media (max-width: 640px) {
  .row-carousel-track > * { flex: 0 0 calc((100% - 18px) / 2); }
  .row-carousel-nav { width: 32px; height: 32px; }
  .row-carousel-nav.prev { left: -8px; }
  .row-carousel-nav.next { right: -8px; }
}
@media (max-width: 420px) {
  .row-carousel-track > * { flex: 0 0 82%; }
}

/* Cards / grids */
.card-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 18px; margin-top: 20px; }
.card-grid-3 { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.service-card, .blog-card, .amc-card-full { display: block; background: var(--white); border: 1px solid var(--gray-200);
  border-radius: var(--radius); padding: 22px; box-shadow: var(--shadow); transition: transform .15s ease; }
.service-card:hover, .blog-card:hover, .amc-card-full:hover { transform: translateY(-3px); }
.amc-card { display: block; background: var(--gray-100); border-radius: var(--radius); padding: 14px 18px; font-weight: 600; color: var(--navy-800); }
.feature-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 26px; margin-top: 24px; }
.feature-grid h4 { color: var(--cyan-300); }

/* Chips */
.chip-row { display: flex; flex-wrap: wrap; gap: 10px; margin: 14px 0; }
.chip { background: var(--gray-100); border-radius: 999px; padding: 8px 16px; font-size: .9rem; color: var(--blue-700); font-weight: 500; }
.chip:hover { background: var(--blue-600); color: var(--white); }
.chip-static { cursor: default; }
.chip-static:hover { background: var(--gray-100); color: var(--blue-700); }

/* Breadcrumbs */
.breadcrumbs { background: var(--gray-100); padding: 10px 0; }
.breadcrumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; margin: 0; padding: 0 20px; max-width: 1180px; margin-inline: auto; font-size: .85rem; }
.breadcrumbs li:not(:last-child)::after { content: '/'; margin-left: 6px; color: var(--gray-500); }

/* CTA blocks */
.cta-block, .cta-inline { background: var(--gray-100); border-radius: var(--radius); padding: 26px; margin: 30px 0; text-align: center; }
.cta-block .btn, .cta-inline .btn { margin: 6px; }
.cta-banner { background: linear-gradient(135deg, var(--blue-700), var(--navy-900)); color: var(--white); text-align: center; }
.cta-banner h2 { color: var(--white); }
.cta-banner .btn { margin: 8px; }

/* FAQ accordion */
.faq-accordion details { border: 1px solid var(--gray-200); border-radius: var(--radius); padding: 14px 18px; margin-bottom: 10px; }
.faq-accordion summary { cursor: pointer; font-weight: 600; color: var(--navy-800); }

/* Forms */
.enquiry-form { display: grid; gap: 14px; background: var(--white); border: 1px solid var(--gray-200); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow); }
.enquiry-form label { display: flex; flex-direction: column; gap: 6px; font-weight: 600; font-size: .9rem; color: var(--gray-700); }
.enquiry-form input, .enquiry-form select, .enquiry-form textarea { padding: 10px 12px; border: 1px solid var(--gray-200); border-radius: 8px; font-family: inherit; font-size: 1rem; }
.form-error { color: #b91c1c; font-weight: 600; }
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 30px; margin-top: 20px; }
.search-form { display: flex; gap: 10px; margin: 16px 0; }
.search-form input { flex: 1; padding: 10px 14px; border-radius: 8px; border: 1px solid var(--gray-200); }

/* Footer */
.site-footer { background: var(--navy-900); color: #b6c6e6; padding: 50px 0 20px; }
.footer-grid { display: grid; grid-template-columns: 2fr repeat(4, 1fr); gap: 24px; }
.footer-col h4 { color: var(--white); font-size: 1rem; }
.footer-col ul { list-style: none; padding: 0; margin: 0; }
.footer-col li { margin-bottom: 8px; }
.footer-col a { color: #b6c6e6; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.1); margin-top: 30px; padding-top: 16px; font-size: .85rem; }

/* WhatsApp float */
.whatsapp-float { position: fixed; bottom: 24px; right: 24px; background: #25d366; border-radius: 50%; width: 56px; height: 56px;
  display: flex; align-items: center; justify-content: center; box-shadow: 0 6px 18px rgba(0,0,0,.2); z-index: 200; }

.pagination { display: flex; gap: 8px; margin-top: 20px; }
.pagination a { padding: 8px 14px; border-radius: 8px; background: var(--gray-100); }
.pagination a.active { background: var(--blue-600); color: var(--white); }

.about-home-grid { display: grid; grid-template-columns: 1fr 1.3fr; gap: 28px; align-items: center; margin-top: 20px; }
.about-home-img { border-radius: var(--radius); box-shadow: var(--shadow); width: 100%; }
@media (max-width: 900px) { .about-home-grid { grid-template-columns: 1fr; } }
.demo-note { background: #fff7ed; border: 1px solid #fdba74; color: #9a3412; padding: 10px 14px; border-radius: 8px; font-size: .85rem; margin-bottom: 14px; }

/* Page banner (hero image at top of inner pages) */
.page-banner { background-size: cover; background-position: center; position: relative; min-height: 220px; display: flex; align-items: center; }
.page-banner-overlay { width: 100%; background: linear-gradient(90deg, rgba(6,18,43,.82), rgba(6,18,43,.35)); padding: 40px 0; }
.page-banner h1 { color: var(--white); margin: 0 0 6px; }
.page-banner p { color: #cfe0ff; margin: 0; font-size: 1.05rem; }

/* Homepage slider — sized to the banner graphics' own 1600x667 (~2.4:1)
   design ratio via aspect-ratio, instead of a flat pixel height, so the
   full banner (including the headline text baked into its top edge)
   always shows without being cropped at any viewport width. */
.hero-slider { position: relative; overflow: hidden; background: var(--navy-900); }
.hero-slider .slide { display: none; }
.hero-slider .slide.active { display: block; }
.hero-slider .slide a { display: block; }
.hero-slider img { width: 100%; aspect-ratio: 1600 / 667; object-fit: contain; display: block; }
.hero-slider .slide-caption { position: absolute; left: 0; right: 0; bottom: 0; padding: 18px 5%; background: linear-gradient(0deg, rgba(6,18,43,.75), transparent); color: var(--white); }
.hero-slider .slide-caption h2 { color: var(--white); margin: 0 0 4px; font-size: clamp(1.1rem, 3vw, 1.6rem); }
.hero-slider .slide-caption p { margin: 0; font-size: .95rem; opacity: .9; }
.hero-slider .slider-nav { position: absolute; top: 50%; transform: translateY(-50%); background: rgba(6,18,43,.55); color: #fff; border: none; width: 42px; height: 42px; border-radius: 50%; cursor: pointer; font-size: 1.3rem; z-index: 5; }
.hero-slider .slider-nav.prev { left: 14px; }
.hero-slider .slider-nav.next { right: 14px; }
.hero-slider .slider-dots { position: absolute; bottom: 16px; left: 50%; transform: translateX(-50%); display: flex; gap: 6px; z-index: 5; }
.hero-slider .slider-dots button { width: 9px; height: 9px; border-radius: 50%; border: none; background: rgba(255,255,255,.5); cursor: pointer; padding: 0; }
.hero-slider .slider-dots button.active { background: var(--white); }
/* No mobile height override needed: aspect-ratio above already scales the
   slide to the correct height at any width, full image, never cropped. */

/* Clients page */
.client-logo-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 20px; margin: 24px 0; }
.client-logo-card { background: var(--white); border: 1px solid var(--gray-200); border-radius: var(--radius); padding: 18px; display: flex; align-items: center; justify-content: center; height: 100px; }
.client-logo-card img { max-height: 60px; max-width: 100%; object-fit: contain; filter: grayscale(15%); }
.testimonial-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 20px; margin-top: 20px; }
.testimonial-card { background: var(--gray-100); border-radius: var(--radius); padding: 22px; }
.testimonial-card .quote-mark { font-size: 2rem; color: var(--cyan-400); line-height: 1; }
.testimonial-name { font-weight: 700; color: var(--navy-800); margin-top: 10px; }
.testimonial-role { font-size: .85rem; color: var(--gray-500); }

/* Team page */
.team-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 22px; margin-top: 22px; }
.team-card { background: var(--white); border: 1px solid var(--gray-200); border-radius: var(--radius); overflow: hidden; text-align: center; box-shadow: var(--shadow); }
.team-card .team-photo { width: 100%; aspect-ratio: 1/1; background: var(--gray-100); display: flex; align-items: center; justify-content: center; overflow: hidden; }
.team-card .team-photo img { width: 100%; height: 100%; object-fit: cover; }
.team-card .team-info { padding: 16px; }
.team-card .team-role { color: var(--cyan-400); font-weight: 600; font-size: .85rem; text-transform: uppercase; letter-spacing: .04em; }

@media (max-width: 600px) {
  .page-banner { min-height: 150px; }
  .hero-slider .slider-nav { width: 34px; height: 34px; font-size: 1.05rem; }
}

/* ===================== Responsive breakpoints ===================== */
@media (max-width: 1024px) {
  .container { padding: 0 16px; }
  .footer-grid { grid-template-columns: repeat(3, 1fr); }
  .contact-grid { grid-template-columns: 1fr 1fr; gap: 20px; }
}

@media (max-width: 900px) {
  .header-cta { display: none; }
  .mobile-toggle { display: block; }
  .main-nav { display: none; position: absolute; top: 100%; left: 0; right: 0; background: var(--white); box-shadow: var(--shadow); }
  .main-nav.mobile-open { display: block; }
  .main-nav ul { flex-direction: column; gap: 0; padding: 10px 0; }
  .main-nav li { border-bottom: 1px solid var(--gray-200); }
  .main-nav a { display: block; padding: 12px 20px; }
  /* Reset the desktop centering trick (left:50% + translateX(-50%) and the
     min(94vw,1100px) width) — position:static alone doesn't cancel a
     transform, so without this the flyout still shifts itself half its
     own width to the left and spills off the left edge of the screen. */
  .has-mega .mega-menu { display: none !important; position: static; left: auto; top: auto; transform: none; width: auto; max-height: none; overflow-y: visible; box-shadow: none; grid-template-columns: 1fr; min-width: 0; padding: 0 20px 10px; }
  .has-mega.mobile-mega-open .mega-menu { display: grid !important; }
  .footer-grid, .contact-grid { grid-template-columns: 1fr; }
  .hero { padding: 60px 0; }
}

@media (max-width: 600px) {
  .card-grid, .card-grid-3 { grid-template-columns: 1fr; }
  .feature-grid { grid-template-columns: 1fr; }
  .hero-cta { flex-direction: column; align-items: stretch; }
  .hero-cta .btn { width: 100%; text-align: center; }
  .cta-block .btn, .cta-inline .btn, .cta-banner .btn { display: block; width: 100%; margin: 6px 0; }
  .client-logo-grid { grid-template-columns: repeat(2, 1fr); }
  .team-grid { grid-template-columns: repeat(2, 1fr); }
}

/* =============================================================
   Scroll-reveal animation utility ([data-aos] on any element)
   — tuned for a slower, more subtle feel
   ============================================================= */
[data-aos] {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 1s cubic-bezier(.22,.61,.36,1), transform 1s cubic-bezier(.22,.61,.36,1);
  will-change: opacity, transform;
}
[data-aos].aos-animate { opacity: 1; transform: translateY(0); }
[data-aos="zoom-in"] { transform: translateY(10px) scale(.96); }
[data-aos="zoom-in"].aos-animate { transform: translateY(0) scale(1); }
[data-aos="fade-left"] { transform: translateX(-20px); }
[data-aos="fade-left"].aos-animate { transform: translateX(0); }
[data-aos="fade-right"] { transform: translateX(20px); }
[data-aos="fade-right"].aos-animate { transform: translateX(0); }
@media (prefers-reduced-motion: reduce) {
  [data-aos] { transition: none !important; opacity: 1 !important; transform: none !important; }
  .brand-track { animation: none !important; }
}

/* =============================================================
   Icon badges — Core Services, AMC cards, Why Choose Us features
   — softer, light-tinted outline style instead of solid fill.
   Icons are inline SVG (see icon_svg() in functions.php) so they
   always render — no external icon-font CDN required.
   ============================================================= */
.card-icon {
  display: inline-flex; align-items: center; justify-content: center;
  width: 54px; height: 54px; border-radius: 14px; margin-bottom: 14px;
  background: rgba(15, 86, 196, .08);
  border: 1px solid rgba(15, 86, 196, .18);
  color: var(--blue-600);
  transition: transform .3s ease, background .3s ease, color .3s ease;
}
.card-icon svg { display: block; }
.service-card:hover .card-icon { transform: translateY(-3px); background: var(--blue-600); color: var(--white); }

.amc-card {
  display: flex; align-items: center; gap: 12px;
  transition: transform .3s ease, box-shadow .3s ease, background .3s ease;
}
.amc-card:hover { transform: translateY(-3px); background: var(--white); box-shadow: var(--shadow); }
.amc-icon {
  flex: 0 0 auto; width: 38px; height: 38px; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  background: rgba(15, 86, 196, .07); border: 1px solid rgba(15, 86, 196, .16);
  color: var(--blue-600);
  transition: background .3s ease, color .3s ease;
}
.amc-icon svg { display: block; }
.amc-card:hover .amc-icon { background: var(--blue-600); color: var(--white); }

.feature-grid > div { position: relative; }
.feature-icon {
  display: inline-flex; align-items: center; justify-content: center;
  width: 50px; height: 50px; border-radius: 50%; margin-bottom: 12px;
  background: rgba(95, 212, 255, .09); color: var(--cyan-300);
  border: 1px solid rgba(95, 212, 255, .3);
  transition: transform .3s ease, background .3s ease;
}
.feature-icon svg { display: block; }
.feature-grid > div:hover .feature-icon { transform: translateY(-3px); background: rgba(95, 212, 255, .18); }

/* =============================================================
   Industries We Serve — image cards
   ============================================================= */
.industry-grid { /* layout now comes from .row-carousel-track (see above) */ }
.industry-card {
  position: relative; display: block; background: var(--white);
  border: 1px solid var(--gray-200); border-radius: var(--radius);
  overflow: hidden; box-shadow: var(--shadow);
  transition: transform .35s ease, box-shadow .35s ease;
}
.industry-card:hover { transform: translateY(-5px); box-shadow: 0 16px 32px rgba(10,31,71,.14); }
/* Industry photos are portrait crops (~379x507, ~3:4) — size the box to
   that ratio via aspect-ratio (instead of a flat 150px height meant for
   a landscape card) and use object-fit: contain so the full photo shows
   with no cropping regardless of container width. */
.industry-card-img { position: relative; aspect-ratio: 3 / 4; overflow: hidden; background: var(--gray-100); }
.industry-card-img img { width: 100%; height: 100%; object-fit: contain; transition: transform .6s ease; }
.industry-card:hover .industry-card-img img { transform: scale(1.06); }
.industry-icon {
  position: absolute; right: 12px; bottom: -18px; width: 40px; height: 40px;
  border-radius: 50%; background: rgba(6, 18, 43, .55); backdrop-filter: blur(2px);
  border: 1px solid rgba(255,255,255,.5);
  color: var(--white); display: flex; align-items: center; justify-content: center;
  box-shadow: 0 6px 14px rgba(10,31,71,.25);
  transition: transform .3s ease, background .3s ease;
}
.industry-icon svg { display: block; }
.industry-card:hover .industry-icon { transform: scale(1.1); background: var(--blue-600); }
.industry-card h3 { padding: 26px 16px 16px; margin: 0; font-size: 1rem; text-align: center; }

/* =============================================================
   Brands That Trust Us — animated logo marquee
   — slower pace, right-to-left source scroll reversed to
   scroll toward the right
   ============================================================= */
.brand-marquee { position: relative; overflow: hidden; margin: 22px 0 6px; }
.brand-marquee::before, .brand-marquee::after {
  content: ''; position: absolute; top: 0; bottom: 0; width: 70px; z-index: 2; pointer-events: none;
}
.brand-marquee::before { left: 0; background: linear-gradient(90deg, var(--white), rgba(255,255,255,0)); }
.brand-marquee::after { right: 0; background: linear-gradient(270deg, var(--white), rgba(255,255,255,0)); }
.brand-track {
  display: flex; align-items: center; gap: 32px; width: max-content;
  animation: brandScroll 65s linear infinite reverse;
}
.brand-marquee:hover .brand-track { animation-play-state: paused; }
.brand-logo-item {
  flex: 0 0 auto; width: 150px; height: 84px; display: flex; align-items: center; justify-content: center;
  background: var(--white); border: 1px solid var(--gray-200); border-radius: var(--radius); padding: 14px;
}
.brand-logo-item img { max-height: 54px; max-width: 100%; object-fit: contain; filter: grayscale(35%); opacity: .85; transition: filter .3s ease, opacity .3s ease, transform .3s ease; }
.brand-logo-item:hover img { filter: grayscale(0); opacity: 1; transform: scale(1.08); }
@keyframes brandScroll { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* =============================================================
   Service Locations — icon chips
   ============================================================= */
.chip-icon { display: inline-flex; align-items: center; gap: 7px; }
.chip-icon svg { display: block; flex: 0 0 auto; color: var(--blue-600); transition: color .2s ease, transform .2s ease; }
.chip-icon:hover svg { color: var(--white); transform: scale(1.15); }
