@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@200;300;500;600;700&display=swap');

/* ============================================================
   Costech Canada Inc — Stylesheet (faithful to original design)
   Colors: --primary-blue:#00FFF7  --dark-blue:#005461  --light-blue:#EFFDFC
   ============================================================ */

:root {
  --primary-blue: #00FFF7;
  --dark-blue:    #005461;
  --light-blue:   #EFFDFC;
  --white:        #FFFFFF;
  --black:        #000000;
  --gray:         #6b7280;
  --border:       rgba(0,84,97,0.12);

  --font-body: 'Poppins', -apple-system, "Segoe UI", Helvetica Neue, sans-serif;
  --max-width: min(100%, 1440px);
  --padding-x: 2rem;
  --content-padding-x: calc(var(--padding-x) * 4);
  --content-padding-y: calc(var(--padding-x) * 3);
  --fade: 0.5s ease;
}

/* ---- Reset ---- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-body);
  min-height: 100vh;
  color: var(--black);
  background: var(--white);
  display: flex;
  flex-direction: column;
  align-items: center;
}
img { max-width: 100%; height: auto; display: block; }
a   { text-decoration: none; color: inherit; }

h1,h2,h3,h4,h5,h6 { margin: 0; }
h1 { font-size: 4rem; font-weight: 700; line-height: 1.1; }
h2 { font-size: 2.5rem; font-weight: 700; color: var(--dark-blue); }
h3 { font-size: 1.25rem; font-weight: 600; line-height: 1.75rem; }

/* ============================================================
   LAYOUT HELPERS
   ============================================================ */
.section-wrapper-full-width {
  width: 100%;
  display: flex;
  justify-content: center;
}
.section-wrapper {
  width: var(--max-width);
  padding: var(--content-padding-y) var(--content-padding-x);
}

/* ============================================================
   BUTTONS
   ============================================================ */
.button {
  display: inline-block;
  background-color: var(--primary-blue);
  color: var(--black);
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 300;
  border: none;
  padding: 10px 25px;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
}
.button:hover    { background-color: var(--dark-blue); color: var(--white); }
.button.cta-btn  { padding: 16px 30px; }

/* ============================================================
   NAVIGATION
   ============================================================ */
.header-wrapper {
  display: flex;
  flex-direction: column;
  width: 100%;
}

.nav-wrapper {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 100;
  display: flex;
  justify-content: center;
  background-color: transparent;
  transition: background-color .3s ease, box-shadow .3s ease;
}

.nav-wrapper .nav-inner {
  width: var(--max-width);
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem var(--padding-x);
}

.nav-wrapper .logo img { width: 250px; height: auto; padding-top: 8px; }

.nav-list {
  list-style: none;
  display: flex;
  flex-direction: row;
  gap: 2rem;
  font-weight: 300;
  font-size: 0.9rem;
  align-items: center;
}

.nav-list a,
.nav-list .nav-dropdown-label {
  color: var(--white);
  transition: color 0.2s ease-in-out;
  cursor: pointer;
}
.nav-list a:hover,
.nav-list .nav-dropdown-label:hover { color: var(--primary-blue); }

/* dropdown */
.nav-dropdown { position: relative; }
.nav-dropdown .sub-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background: var(--white);
  box-shadow: 0 4px 16px rgba(0,0,0,.18);
  list-style: none;
  min-width: 280px;
  z-index: 200;
}
.nav-dropdown:hover .sub-menu { display: block; }
.sub-menu li { border-bottom: 1px solid rgba(0,84,97,.1); }
.sub-menu li a {
  display: block;
  padding: .9rem 1.25rem;
  color: var(--black);
  font-size: .85rem;
  transition: background .15s;
}
.sub-menu li:hover { background-color: var(--dark-blue); }
.sub-menu li:hover a { color: var(--white); }

/* logo variants: white wordmark over the hero, black once scrolled */
.nav-wrapper .logo img.logo-black { display: none; }
.nav-wrapper.scrolled .logo img.logo-white { display: none; }
.nav-wrapper.scrolled .logo img.logo-black { display: block; }

/* scrolled state: solid light header with dark text */
.nav-wrapper.scrolled {
  background-color: var(--white);
  box-shadow: 0 2px 12px rgba(0,0,0,.08);
}
.nav-wrapper.scrolled .nav-list a,
.nav-wrapper.scrolled .nav-list .nav-dropdown-label { color: var(--black) !important; }
.nav-wrapper.scrolled .nav-list a:hover,
.nav-wrapper.scrolled .nav-list .nav-dropdown-label:hover { color: var(--dark-blue) !important; }

/* ============================================================
   HERO BANNER
   ============================================================ */
.banner {
  position: relative;
  width: 100%;
  min-height: 600px;
  height: 68vh;
  background-size: cover;
  background-position: center;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  margin-top: 0;
  padding-top: 90px;
  overflow: hidden;
}

/* Carousel slides sit behind content */
.banner-slides {
  position: absolute;
  inset: 0;
}
.banner-slide {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0;
  transition: opacity 1.2s ease-in-out;
}
.banner-slide.active { opacity: 1; }
.banner-slide::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(0,84,97,.62);
}

.banner > *:not(.banner-slides) { position: relative; z-index: 1; }

.banner-content {
  width: var(--max-width);
  padding-left: var(--content-padding-x);
}

.banner-content .header-text {
  display: block;
  font-size: 1.1rem;
  font-weight: 300;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--white);
  margin-bottom: 1rem;
}

.banner-content h1 {
  color: var(--primary-blue);
  font-size: 4.2rem;
  line-height: 1.1;
}

.banner-content .description {
  font-size: 2rem;
  font-weight: 200;
  padding: 1.5rem 0;
  color: var(--white);
}

.banner-content .details {
  font-size: 1.1rem;
  font-weight: 200;
  line-height: 1.85;
  padding-bottom: 2rem;
  width: 58%;
  color: rgba(255,255,255,.85);
}

.banner-content .button { padding: 22px 55px; }

/* ============================================================
   PAGE BANNER (inner pages)
   ============================================================ */
.page-banner {
  position: relative;
  min-height: 28rem;
  width: 100%;
  background-image: url('../assets/images/services/services-desktop-2.jpg');
  background-size: cover;
  background-position: center;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  margin-top: 0;
}
.page-banner::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(0,84,97,.65);
}
.page-banner > * { position: relative; z-index: 1; }
.page-banner .page-banner-content {
  width: var(--max-width);
  padding-left: var(--content-padding-x);
}
.page-banner h1 { color: var(--primary-blue); }

/* ============================================================
   SPECIALIZE SECTION
   ============================================================ */
.specialize-content {
  display: flex;
  flex-direction: row;
  gap: 3rem;
  align-items: center;
}

.specialize-content img {
  width: 45%;
  flex-shrink: 0;
  object-fit: cover;
}

.specialize-content .specialize-text h2 { margin-bottom: 0; }

.specialize-content .specialize-text ul {
  list-style: none;
  padding: 0;
  margin: 2rem 0;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  font-size: 1.3rem;
  font-weight: 500;
  color: var(--dark-blue);
}

/* ============================================================
   SERVICES CLASSIFICATION  (image-background cards)
   ============================================================ */
.services-wrapper {
  width: 100%;
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  margin: 3rem 0;
  gap: 1rem;
}

.service-item {
  display: flex;
  flex-direction: column;
  padding: 2.5rem 1.75rem;
  width: 31%;
  background-size: cover;
  background-position: center;
  min-height: 420px;
  position: relative;
}
.service-item::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(0,84,97,.72);
}
.service-item > * { position: relative; z-index: 1; }

.service-item h3 {
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--primary-blue);
}

.service-item ul {
  list-style: none;
  padding: 0;
  margin: 2rem 0 0;
  display: flex;
  flex-direction: column;
  gap: .85rem;
  color: var(--white);
  font-weight: 300;
  font-size: .95rem;
  line-height: 1.5;
}

/* ============================================================
   RECENT PROJECTS
   ============================================================ */
.recent-projects-content {
  width: 100%;
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  margin: 3rem 0;
  gap: 1rem;
}

.recent-project-item {
  width: 31%;
  display: flex;
  flex-direction: column;
  background-color: var(--dark-blue);
  color: var(--white);
  overflow: hidden;
}

.recent-project-item img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  display: block;
}

.recent-project-item h3 {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--primary-blue);
  padding: 1rem 1.25rem .35rem;
}

.recent-project-item p {
  font-weight: 300;
  font-style: italic;
  font-size: .9rem;
  padding: 0 1.25rem 1.25rem;
  color: rgba(255,255,255,.75);
}

/* ============================================================
   ALL PROJECTS PAGE  (full grid)
   ============================================================ */
.all-projects-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin: 3rem 0;
}

.project-card-full {
  background-color: var(--dark-blue);
  color: var(--white);
  overflow: hidden;
  transition: transform .2s, box-shadow .2s;
}
.project-card-full:hover { transform: translateY(-4px); box-shadow: 0 8px 24px rgba(0,0,0,.25); }

.project-card-full img {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.project-card-full .proj-body { padding: 1.25rem; }
.project-card-full h3 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--primary-blue);
  margin-bottom: .35rem;
}
.project-card-full p {
  font-size: .85rem;
  font-weight: 300;
  font-style: italic;
  color: rgba(255,255,255,.7);
}

/* ============================================================
   VALUES SECTION  (background image)
   ============================================================ */
.values-section {
  width: 100%;
  background-image: url('../assets/images/values/value-desktop.jpg');
  background-size: cover;
  background-position: center;
  position: relative;
}
.values-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(0,84,97,.65);
}
.values-section > * { position: relative; z-index: 1; }

.values-content h2  { color: var(--white); }

.values-list {
  list-style: none;
  padding: 0;
  margin: 3rem 0 0;
  display: flex;
  justify-content: space-between;
  font-size: 2rem;
  font-weight: 600;
  color: var(--primary-blue);
}
.values-list li:not(:first-child) { padding-left: 1.5rem; }
.values-list li:first-child { list-style-type: none; }

/* ============================================================
   ABOUT US SECTION
   ============================================================ */
.about-us-content {
  width: 100%;
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: flex-start;
  margin: 3rem 0;
  gap: 3rem;
}

.about-us-text img {
  float: right;
  margin-left: 2rem;
  margin-bottom: 2rem;
  width: 360px;
}

.about-us-text p {
  font-weight: 200;
  line-height: 1.85;
  color: var(--black);
  font-size: 1rem;
}
.about-us-text p + p { margin-top: 1rem; }
.about-us-text p b   { font-weight: 500; }
.about-us-text .button { margin-top: 1.5rem; }

.about-us-aside {
  min-width: 280px;
  max-width: 300px;
  flex-shrink: 0;
}

.aside-card {
  background: var(--dark-blue);
  color: var(--white);
  padding: 2rem;
  margin-bottom: 1.25rem;
}
.aside-card h3  { color: var(--primary-blue); margin-bottom: 1rem; font-size: 1.1rem; }
.aside-card ul  { list-style: none; padding: 0; }
.aside-card li  { padding: .4rem 0; font-weight: 200; font-size: .9rem; border-bottom: 1px solid rgba(255,255,255,.1); }
.aside-card li:last-child { border-bottom: none; }
.aside-card li::before { content: '· '; color: var(--primary-blue); }

/* ============================================================
   AFFILIATIONS
   ============================================================ */
#prof-affiliations > h2 { font-size: 1.7rem; }

.affiliations-content {
  width: 100%;
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: center;
  margin: 3rem 0;
  gap: 1.5rem;
  flex-wrap: wrap;
}

.affiliations-content img {
  height: 70px;
  width: auto;
  object-fit: contain;
  filter: grayscale(20%);
  transition: filter .2s;
}
.affiliations-content img:hover { filter: none; }

/* ============================================================
   CONTACT SECTION  (background image)
   ============================================================ */
.contact-section {
  width: 100%;
  background-image: url('../assets/images/contact/contact-desktop.jpg');
  background-size: cover;
  background-position: center;
  position: relative;
}
.contact-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(0,84,97,.78);
}
.contact-section > * { position: relative; z-index: 1; }

.contact-content {
  display: flex;
  justify-content: space-between;
  gap: 4rem;
  align-items: flex-start;
}

.contact-us-text h2 { color: var(--white); }

.contact-us-text ul {
  list-style: none;
  padding: 0;
  margin: 2.5rem 0 0;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  font-size: 1.1rem;
  font-weight: 300;
}

.contact-us-text li a {
  display: flex;
  align-items: center;
  gap: 1rem;
  color: var(--white);
  transition: color .2s;
}
.contact-us-text li a:hover { color: var(--primary-blue); }
.contact-us-text li img { width: 40px; height: auto; }

/* Contact Form */
.contact-form-wrap {
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.2);
  padding: 2.5rem;
  min-width: 380px;
  max-width: 420px;
}
.contact-form-wrap h3 { color: var(--white); margin-bottom: 1.5rem; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.form-group { margin-bottom: 1.1rem; }
.form-group label { display: block; font-size: .8rem; font-weight: 500; color: rgba(255,255,255,.75); margin-bottom: .35rem; }
.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: .6rem .9rem;
  border: 1px solid rgba(255,255,255,.3);
  background: rgba(255,255,255,.08);
  color: var(--white);
  font-family: var(--font-body);
  font-size: .9rem;
  outline: none;
  transition: border-color .2s;
}
.form-group input::placeholder,
.form-group textarea::placeholder { color: rgba(255,255,255,.4); }
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus { border-color: var(--primary-blue); }
.form-group select { color: rgba(255,255,255,.7); }
.form-group select option { background: var(--dark-blue); color: var(--white); }
.form-group textarea { resize: vertical; min-height: 100px; }
.form-group.full { grid-column: 1 / -1; }

/* ============================================================
   SERVICES PAGE DETAIL
   ============================================================ */
.services-page-hero {
  background-image: url('../assets/images/services/services-desktop-1.jpg');
}

.service-detail-block {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
  align-items: start;
  padding: 2.5rem 0;
  border-bottom: 1px solid var(--border);
}
.service-detail-block:last-child { border-bottom: none; }
.service-num {
  font-size: 3rem;
  font-weight: 700;
  color: var(--light-blue);
  line-height: 1;
  border: 3px solid var(--light-blue);
  width: 72px;
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  color: var(--dark-blue);
}
.service-detail-block h3 { color: var(--dark-blue); font-size: 1.4rem; margin-bottom: .65rem; }
.service-detail-block p  { font-weight: 200; line-height: 1.8; color: #333; margin-bottom: .75rem; }
.service-detail-block ul { list-style: none; padding: 0; }
.service-detail-block ul li {
  padding: .4rem 0 .4rem 1.25rem;
  position: relative;
  font-weight: 300;
  font-size: .95rem;
  color: #444;
  border-bottom: 1px solid var(--border);
}
.service-detail-block ul li:last-child { border-bottom: none; }
.service-detail-block ul li::before { content: '›'; position: absolute; left: 0; color: var(--dark-blue); font-weight: 700; }

/* Estimate table */
.estimate-table { width: 100%; border-collapse: collapse; margin-top: 1.25rem; }
.estimate-table th {
  background: var(--dark-blue);
  color: var(--white);
  padding: .7rem 1rem;
  text-align: left;
  font-size: .85rem;
  font-weight: 500;
}
.estimate-table td { padding: .7rem 1rem; border-bottom: 1px solid var(--border); font-size: .9rem; font-weight: 300; }
.estimate-table tr:nth-child(even) td { background: var(--light-blue); }

/* ============================================================
   CAREERS
   ============================================================ */
.career-card {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 2rem;
  border: 1px solid var(--border);
  padding: 2rem 2.25rem;
  margin-bottom: 1.5rem;
  transition: box-shadow .2s;
  background: var(--white);
}
.career-card:hover { box-shadow: 0 4px 20px rgba(0,84,97,.12); }
.career-card h3    { color: var(--dark-blue); font-size: 1.15rem; margin-bottom: .45rem; }
.career-card p     { font-weight: 200; line-height: 1.7; color: #444; max-width: 560px; font-size: .95rem; }
.career-meta       { display: flex; flex-wrap: wrap; gap: .6rem; margin-top: .75rem; }
.badge {
  display: inline-block;
  padding: .25rem .75rem;
  font-size: .75rem;
  font-weight: 500;
  border-radius: 2px;
}
.badge-full     { background: rgba(0,255,247,.15); color: var(--dark-blue); }
.badge-contract { background: rgba(0,84,97,.1);    color: var(--dark-blue); }
.badge-open     { background: rgba(0,84,97,.08);   color: var(--dark-blue); }

.career-requirements { list-style: none; padding: 0; margin-top: .75rem; }
.career-requirements li {
  font-size: .88rem;
  font-weight: 200;
  color: #555;
  padding: .3rem 0 .3rem 1.25rem;
  position: relative;
  border-bottom: 1px solid var(--border);
}
.career-requirements li:last-child { border-bottom: none; }
.career-requirements li::before { content: '›'; position: absolute; left: 0; color: var(--dark-blue); }

/* How to Apply steps */
.apply-steps { display: grid; grid-template-columns: repeat(3,1fr); gap: 2rem; margin-top: 2rem; }
.apply-step  { text-align: center; padding: 2rem 1.5rem; }
.apply-step .step-icon { font-size: 2.5rem; margin-bottom: 1rem; }
.apply-step h3 { color: var(--dark-blue); margin-bottom: .75rem; }
.apply-step p  { font-weight: 200; font-size: .92rem; color: #555; line-height: 1.7; }

/* ============================================================
   SECTION HEADERS
   ============================================================ */
.section-label {
  display: inline-block;
  font-size: .75rem;
  font-weight: 600;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--dark-blue);
  margin-bottom: .6rem;
}

.section-divider {
  width: 48px;
  height: 3px;
  background: var(--primary-blue);
  margin: .75rem 0 1.5rem;
}

/* ============================================================
   FOOTER
   ============================================================ */
.footer-wrapper {
  background-color: var(--dark-blue);
  display: flex;
  flex-direction: column;
  font-weight: 300;
  align-items: center;
  padding: 2.5rem 0;
  width: 100%;
}

.footer-nav-wrapper nav ul {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  width: 100%;
  gap: 3rem;
  font-size: 0.9rem;
  list-style: none;
  align-items: center;
  margin-bottom: 2rem;
}

.footer-wrapper nav a { color: var(--white); transition: color .2s; }
.footer-wrapper nav a:hover { color: var(--primary-blue); }

.footer-wrapper .social-media-links {
  display: flex;
  flex-direction: row;
  gap: 2rem;
  margin: 1.5rem 0;
}

.footer-wrapper .social-media-links img { width: 36px; height: auto; }
.footer-wrapper .social-media-links a { transition: opacity .2s; }
.footer-wrapper .social-media-links a:hover { opacity: .7; }

.footer-copyright {
  color: var(--white);
  font-size: 0.8rem;
  font-weight: 300;
  margin-top: 2rem;
  text-align: center;
}

/* ============================================================
   FADE-IN ANIMATION
   ============================================================ */
[data-loaded] {
  transition: var(--fade);
  transition-property: opacity, transform;
}
[data-loaded="false"] {
  transform: translateY(24px);
  opacity: 0;
}
[data-loaded="true"] {
  transform: translateY(0);
  opacity: 1;
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1100px) {
  :root {
    --content-padding-x: 2.5rem;
    --content-padding-y: 4rem;
  }
  .banner-content .details { width: 75%; }
}

@media (max-width: 800px) {
  :root { --content-padding-x: 1.5rem; }
  h1 { font-size: 2.5rem; }
  h2 { font-size: 1.8rem; }

  .specialize-content  { flex-direction: column; }
  .specialize-content img { width: 100%; }
  .services-wrapper    { flex-direction: column; gap: 1.5rem; }
  .service-item        { width: 100%; }
  .recent-projects-content { flex-wrap: wrap; }
  .recent-project-item { width: 100%; }
  .all-projects-grid   { grid-template-columns: 1fr 1fr; }
  .values-list         { flex-direction: column; gap: 1rem; font-size: 1.5rem; }
  .about-us-content    { flex-direction: column; }
  .about-us-aside      { max-width: 100%; min-width: 0; }
  .affiliations-content { overflow-x: auto; flex-wrap: nowrap; justify-content: flex-start; }
  .contact-content     { flex-direction: column; }
  .contact-form-wrap   { min-width: 0; max-width: 100%; width: 100%; }
  .service-detail-block { grid-template-columns: 1fr; }
  .apply-steps         { grid-template-columns: 1fr; }
  .career-card         { flex-direction: column; }
  .form-row            { grid-template-columns: 1fr; }
  .banner-content      { padding-left: 1.5rem; }
  .banner-content .details { width: 100%; }
  .nav-list            { gap: .85rem; font-size: .82rem; }
}

@media (max-width: 560px) {
  .all-projects-grid { grid-template-columns: 1fr; }
  .nav-list .nav-dropdown { display: none; }
}
