/* ============================================================
   ICE, Innovative Contracting & Engineering
   Shared design system
   ============================================================ */

:root {
  --navy: #07384F;
  --navy-deep: #052736;
  --coral: #E05535;
  --coral-dark: #C2431F;
  --text: #0D2B3E;
  --text-soft: #4A6072;
  --surface: #F5F5F5;
  --surface-alt: #FAFAFA;
  --white: #FFFFFF;
  --line: #E4E9EC;

  --container: 1240px;
  --radius: 6px;
  --shadow: 0 12px 32px rgba(7, 56, 79, 0.10);
  --shadow-sm: 0 4px 14px rgba(7, 56, 79, 0.08);

  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  color: var(--text);
  background: var(--white);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 32px;
}

section { position: relative; }

/* ---------- Typography ---------- */

h1, h2, h3, h4 {
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.01em;
  color: var(--navy);
}

h1 { font-size: clamp(2.4rem, 4.5vw, 4rem); }
h2 { font-size: clamp(1.9rem, 3.2vw, 2.75rem); }
h3 { font-size: 1.35rem; }

p { color: var(--text-soft); }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--coral);
  margin-bottom: 16px;
}
.eyebrow::before {
  content: '';
  width: 28px;
  height: 2px;
  background: var(--coral);
}

.section-head {
  max-width: 640px;
  margin-bottom: 48px;
}
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }
.section-head p { margin-top: 16px; font-size: 1.05rem; }

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 15px 30px;
  border-radius: 3px;
  font-weight: 700;
  font-size: 0.88rem;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  border: 2px solid transparent;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}
.btn-primary { background: var(--coral); color: var(--white); }
.btn-primary:hover { background: var(--coral-dark); transform: translateY(-2px); }
.btn-outline { border-color: var(--navy); color: var(--navy); }
.btn-outline:hover { background: var(--navy); color: var(--white); }
.btn-outline-light { border-color: rgba(255,255,255,0.5); color: var(--white); }
.btn-outline-light:hover { background: var(--white); color: var(--navy); border-color: var(--white); }
.btn-white { background: var(--white); color: var(--navy); }
.btn-white:hover { background: var(--coral); color: var(--white); transform: translateY(-2px); }

/* ---------- Header ---------- */

.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  background: var(--white);
  box-shadow: 0 2px 20px rgba(7,56,79,0.08);
  transition: box-shadow 0.3s ease, padding 0.3s ease;
  padding: 16px 0;
}
.site-header.scrolled {
  padding: 12px 0;
  box-shadow: 0 2px 24px rgba(7,56,79,0.14);
}
.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.brand { display: flex; align-items: center; gap: 10px; }
.brand img { height: 40px; width: auto; }

.nav-links {
  display: flex;
  align-items: center;
  gap: 40px;
}
.nav-links a {
  font-size: 0.88rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--navy);
  position: relative;
  padding: 6px 0;
}
.nav-links a.active,
.nav-links a:hover { color: var(--coral); }

.header-cta { display: flex; align-items: center; gap: 24px; }
.header-phone {
  display: flex; align-items: center; gap: 8px;
  font-size: 0.85rem; font-weight: 600; color: var(--navy);
}

.employee-dropdown { position: relative; }
.employee-toggle {
  display: flex; align-items: center; gap: 8px;
  padding: 11px 18px;
  border: 2px solid var(--navy);
  border-radius: 3px;
  background: none;
  color: var(--navy);
  font-family: var(--font);
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  cursor: pointer;
  transition: all 0.2s ease;
}
.employee-toggle:hover { background: var(--navy); color: var(--white); }
.employee-toggle svg { width: 14px; height: 14px; transition: transform 0.2s ease; flex-shrink: 0; }
.employee-dropdown.open .employee-toggle svg { transform: rotate(180deg); }

.employee-menu {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  min-width: 260px;
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  border: 1px solid var(--line);
  padding: 8px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-8px);
  transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
  z-index: 1100;
}
.employee-dropdown.open .employee-menu {
  opacity: 1; visibility: visible; transform: translateY(0);
}
.employee-menu a {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 14px;
  border-radius: 4px;
  font-size: 0.88rem; font-weight: 600; color: var(--navy);
}
.employee-menu a:hover { background: var(--surface); color: var(--coral); }
.employee-menu a svg { width: 18px; height: 18px; flex-shrink: 0; color: var(--coral); }
.employee-menu .menu-note {
  padding: 8px 14px 4px; font-size: 0.72rem; color: var(--text-soft);
  text-transform: uppercase; letter-spacing: 0.05em; font-weight: 700;
}

.mobile-nav .employee-section {
  margin-top: 8px;
  padding-top: 28px;
  border-top: 1px solid rgba(255,255,255,0.15);
  width: 100%;
}
.mobile-nav .employee-section .menu-note {
  color: rgba(255,255,255,0.5);
  font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.06em; font-weight: 700;
  margin-bottom: 14px;
}
.mobile-nav .employee-section a {
  font-size: 1.1rem; font-weight: 600; display: block; margin-bottom: 14px;
}

.nav-toggle {
  display: none;
  background: none; border: none; cursor: pointer;
  width: 32px; height: 24px; position: relative;
}
.nav-toggle span {
  position: absolute; left: 0; width: 100%; height: 2px;
  background: var(--navy); transition: all 0.25s ease;
}
.nav-toggle span:nth-child(1) { top: 0; }
.nav-toggle span:nth-child(2) { top: 11px; }
.nav-toggle span:nth-child(3) { top: 22px; }

/* ---------- Hero ---------- */

.hero {
  min-height: 100vh;
  display: flex;
  align-items: flex-end;
  position: relative;
  background-size: cover;
  background-position: center;
  color: var(--white);
}
.hero::after {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(7,38,54,0.55) 0%, rgba(5,24,33,0.55) 45%, rgba(5,24,33,0.92) 100%);
}
.hero-inner {
  position: relative;
  z-index: 2;
  padding-bottom: 100px;
  padding-top: 180px;
  width: 100%;
}
.hero .eyebrow { color: #FF9C7F; }
.hero .eyebrow::before { background: #FF9C7F; }
.hero h1 { color: var(--white); max-width: 900px; }
.hero-lead {
  margin-top: 22px;
  font-size: 1.2rem;
  color: rgba(255,255,255,0.85);
  max-width: 560px;
}
.hero-actions { margin-top: 40px; display: flex; gap: 16px; flex-wrap: wrap; }

.hero-stats {
  position: relative;
  z-index: 2;
  border-top: 1px solid rgba(255,255,255,0.18);
  margin-top: 64px;
  padding-top: 36px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}
.hero-stat .num {
  font-size: clamp(1.7rem, 2.6vw, 2.3rem);
  font-weight: 800;
  color: var(--white);
  display: flex;
  align-items: baseline;
  gap: 2px;
}
.hero-stat .num span.plus { color: var(--coral); }
.hero-stat .label {
  font-size: 0.8rem;
  color: rgba(255,255,255,0.65);
  margin-top: 4px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* Page header (non-home hero, shorter) */
.page-hero {
  min-height: 56vh;
  display: flex;
  align-items: flex-end;
  position: relative;
  background-size: cover;
  background-position: center;
  color: var(--white);
}
.page-hero::after {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(7,38,54,0.55) 0%, rgba(5,24,33,0.88) 100%);
}
.page-hero-inner { position: relative; z-index: 2; padding: 180px 0 64px; }
.page-hero h1 { color: var(--white); }
.breadcrumb {
  display: flex; gap: 8px; align-items: center;
  font-size: 0.82rem; color: rgba(255,255,255,0.7);
  text-transform: uppercase; letter-spacing: 0.06em; margin-bottom: 18px;
}
.breadcrumb a:hover { color: var(--coral); }

/* ---------- Cards / grids ---------- */

.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 28px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }

.service-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 36px 30px;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}
.service-card:hover { transform: translateY(-6px); box-shadow: var(--shadow); border-color: transparent; }
.service-card .icon {
  width: 52px; height: 52px;
  display: flex; align-items: center; justify-content: center;
  background: rgba(224, 85, 53, 0.1);
  border-radius: 10px;
  margin-bottom: 22px;
  color: var(--coral);
}
.service-card .icon svg { width: 26px; height: 26px; }
.service-card h3 { margin-bottom: 10px; }
.service-card p { font-size: 0.95rem; }

.metric-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px 24px;
  position: relative;
  overflow: hidden;
  text-align: center;
}
.metric-card::before {
  content: '';
  position: absolute; top: 0; left: 0; right: 0; height: 4px;
  background: var(--coral);
}
.metric-card .num { font-size: 2.1rem; font-weight: 800; color: var(--navy); }
.metric-card .label { font-size: 0.82rem; color: var(--text-soft); margin-top: 6px; text-transform: uppercase; letter-spacing: 0.04em; }

/* Project cards */
.project-card {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  aspect-ratio: 4/5;
  background: var(--navy);
  display: block;
}
.project-card img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform 0.5s ease;
}
.project-card:hover img { transform: scale(1.08); }
.project-card::after {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(7,38,54,0) 40%, rgba(5,24,33,0.92) 100%);
}
.project-card .info {
  position: absolute; left: 0; right: 0; bottom: 0;
  z-index: 2;
  padding: 26px 24px;
  color: var(--white);
}
.project-card .tag {
  font-size: 0.72rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--coral); margin-bottom: 8px; display: block;
}
.project-card .info h3 { color: var(--white); font-size: 1.15rem; margin-bottom: 4px; }
.project-card .info .meta { color: rgba(255,255,255,0.72); font-size: 0.85rem; }

.project-card.wide { aspect-ratio: 8/5; }

/* Filter pills */
.filter-bar {
  display: flex; flex-wrap: wrap; gap: 10px;
  margin-bottom: 44px;
}
.filter-pill {
  padding: 10px 20px;
  border: 1px solid var(--line);
  border-radius: 30px;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  background: var(--white);
  color: var(--text-soft);
  transition: all 0.2s ease;
}
.filter-pill:hover { border-color: var(--coral); color: var(--coral); }
.filter-pill.active { background: var(--navy); border-color: var(--navy); color: var(--white); }

/* ---------- Sections ---------- */

.section { padding: 110px 0; }
.section-sm { padding: 70px 0; }
.bg-surface { background: var(--surface); }
.bg-navy { background: var(--navy); color: var(--white); }
.bg-navy h2, .bg-navy h3, .bg-navy h4 { color: var(--white); }
.bg-navy p { color: rgba(255,255,255,0.72); }

.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 72px;
  align-items: center;
}
.split img { border-radius: var(--radius); }
.split-media { position: relative; }
.split-media .badge-card {
  position: absolute;
  bottom: -28px; left: -28px;
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 22px 26px;
  display: flex; align-items: center; gap: 16px;
}
.split-media .badge-card .num { font-size: 1.8rem; font-weight: 800; color: var(--coral); }
.split-media .badge-card .label { font-size: 0.8rem; color: var(--text-soft); max-width: 120px; }

/* Timeline (About) */
.timeline { position: relative; padding-left: 36px; border-left: 2px solid var(--line); }
.timeline-item { position: relative; padding-bottom: 44px; }
.timeline-item:last-child { padding-bottom: 0; }
.timeline-item::before {
  content: '';
  position: absolute; left: -43px; top: 4px;
  width: 14px; height: 14px; border-radius: 50%;
  background: var(--coral);
  border: 3px solid var(--white);
  box-shadow: 0 0 0 2px var(--coral);
}
.timeline-item .year { font-weight: 800; color: var(--coral); font-size: 0.9rem; letter-spacing: 0.04em; margin-bottom: 6px; }

/* Innovation / tech feature row */
.tech-row {
  display: grid;
  grid-template-columns: 90px 1fr;
  gap: 26px;
  padding: 34px 0;
  border-bottom: 1px solid var(--line);
}
.tech-row:first-of-type { padding-top: 0; }
.tech-row:last-of-type { border-bottom: none; }
.tech-row .tech-icon {
  width: 64px; height: 64px;
  border-radius: 50%;
  background: var(--surface);
  display: flex; align-items: center; justify-content: center;
  color: var(--coral);
}
.tech-row .tech-icon svg { width: 30px; height: 30px; }
.tech-row h3 { margin-bottom: 8px; }
.tech-row p { max-width: 620px; }

/* Logos strip */
.logo-strip {
  display: flex; flex-wrap: wrap; gap: 48px; align-items: center; justify-content: space-between;
  opacity: 0.6;
}
.logo-strip span { font-weight: 800; font-size: 1.1rem; color: var(--navy); letter-spacing: 0.02em; }

/* Team / value cards */
.value-card { display: flex; gap: 18px; }
.value-card .icon {
  flex-shrink: 0;
  width: 46px; height: 46px; border-radius: 8px;
  background: rgba(224,85,53,0.1); color: var(--coral);
  display: flex; align-items: center; justify-content: center;
}
.value-card .icon svg { width: 22px; height: 22px; }
.value-card h4 { margin-bottom: 6px; font-size: 1.05rem; }
.value-card p { font-size: 0.92rem; }

/* CTA band */
.cta-band {
  background: var(--navy);
  border-left: 4px solid var(--coral);
  padding: 56px 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 40px;
  flex-wrap: wrap;
  color: var(--white);
}
.cta-band h2 { color: var(--white); max-width: 480px; }
.cta-band .cta-actions { display: flex; gap: 16px; flex-wrap: wrap; }

/* Contact page */
.contact-grid { display: grid; grid-template-columns: 1fr 1.2fr; gap: 60px; }
.contact-card {
  display: flex; gap: 18px;
  padding: 26px 0;
  border-bottom: 1px solid var(--line);
}
.contact-card:first-child { padding-top: 0; }
.contact-card .icon {
  flex-shrink: 0; width: 46px; height: 46px; border-radius: 8px;
  background: rgba(7,56,79,0.06); color: var(--navy);
  display: flex; align-items: center; justify-content: center;
}
.contact-card .icon svg { width: 22px; height: 22px; }
.contact-card h4 { font-size: 0.95rem; margin-bottom: 4px; }
.contact-card p { font-size: 0.92rem; margin: 0; }
.contact-card a:hover { color: var(--coral); }

.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.form-field { display: flex; flex-direction: column; gap: 8px; margin-bottom: 20px; }
.form-field.full { grid-column: 1 / -1; }
.form-field label { font-size: 0.8rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; color: var(--navy); }
.form-field input, .form-field select, .form-field textarea {
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 13px 16px;
  font-family: var(--font);
  font-size: 0.95rem;
  color: var(--text);
  background: var(--white);
  transition: border-color 0.2s ease;
}
.form-field input:focus, .form-field select:focus, .form-field textarea:focus {
  outline: none; border-color: var(--coral);
}
.form-field textarea { resize: vertical; min-height: 130px; }

.map-embed {
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line);
  height: 340px;
}
.map-embed iframe { width: 100%; height: 100%; border: 0; }

/* ---------- Footer ---------- */

.site-footer { background: var(--navy-deep); color: rgba(255,255,255,0.7); padding-top: 80px; }
.footer-top { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 50px; padding-bottom: 60px; }
.footer-top img { height: 42px; margin-bottom: 20px; }
.footer-top p { font-size: 0.9rem; color: rgba(255,255,255,0.55); }
.footer-col h4 { color: var(--white); font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.06em; margin-bottom: 20px; }
.footer-col ul li { margin-bottom: 12px; font-size: 0.9rem; }
.footer-col ul li a:hover { color: var(--coral); }
.footer-social { display: flex; gap: 12px; margin-top: 22px; }
.footer-social a {
  width: 36px; height: 36px; border-radius: 50%;
  border: 1px solid rgba(255,255,255,0.2);
  display: flex; align-items: center; justify-content: center;
  transition: all 0.2s ease;
}
.footer-social a:hover { background: var(--coral); border-color: var(--coral); }
.footer-social svg { width: 16px; height: 16px; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.4);
  padding: 24px 0;
  display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px;
  font-size: 0.82rem;
}
.footer-bottom-rule { height: 2px; background: var(--coral); }

/* ---------- Responsive ---------- */

@media (max-width: 980px) {
  .grid-3, .grid-2 { grid-template-columns: 1fr; }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .split { grid-template-columns: 1fr; gap: 40px; }
  .hero-stats { grid-template-columns: repeat(2, 1fr); }
  .footer-top { grid-template-columns: 1fr 1fr; }
  .contact-grid { grid-template-columns: 1fr; }
  .form-grid { grid-template-columns: 1fr; }
  .project-layout { grid-template-columns: 1fr; gap: 40px; }
}

@media (max-width: 760px) {
  .nav-links, .header-cta .header-phone, .header-cta .employee-dropdown { display: none; }
  .nav-toggle { display: block; }
  .grid-4 { grid-template-columns: 1fr; }
  .footer-top { grid-template-columns: 1fr; }
  .cta-band { padding: 40px 28px; flex-direction: column; align-items: flex-start; }
  .section { padding: 70px 0; }
  .container { padding: 0 22px; }
  .tech-row { grid-template-columns: 56px 1fr; }
}

/* Mobile nav drawer */
.mobile-nav {
  position: fixed; inset: 0; z-index: 999;
  background: var(--navy);
  display: flex; flex-direction: column;
  align-items: flex-start; justify-content: center;
  gap: 28px; padding: 40px;
  transform: translateX(100%);
  transition: transform 0.35s ease;
}
.mobile-nav.open { transform: translateX(0); }
.mobile-nav a { color: var(--white); font-size: 1.6rem; font-weight: 700; }
.mobile-nav a.active, .mobile-nav a:hover { color: var(--coral); }

/* Reveal animation */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity 0.7s ease, transform 0.7s ease; }
.reveal.in { opacity: 1; transform: translateY(0); }

/* ---------- Project detail page ---------- */

.project-layout {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 60px;
  align-items: flex-start;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}
.gallery-item {
  display: block;
  border-radius: var(--radius);
  overflow: hidden;
  aspect-ratio: 4/3;
  cursor: zoom-in;
}
.gallery-item img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform 0.4s ease;
}
.gallery-item:hover img { transform: scale(1.05); }
.gallery-grid:has(.gallery-item:only-child) { grid-template-columns: 1fr; }
.gallery-grid:has(.gallery-item:only-child) .gallery-item { aspect-ratio: 16/9; }

.detail-fields {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 8px 24px;
  margin-bottom: 24px;
}
.detail-field {
  display: flex; justify-content: space-between; gap: 16px;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}
.detail-field:last-child { border-bottom: none; }
.detail-label {
  font-size: 0.78rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em;
  color: var(--text-soft);
}
.detail-value { font-size: 0.92rem; font-weight: 600; color: var(--navy); text-align: right; }

.lightbox {
  position: fixed; inset: 0; z-index: 2000;
  background: rgba(5,24,33,0.94);
  display: none;
  align-items: center; justify-content: center;
}
.lightbox.open { display: flex; }
.lightbox img {
  max-width: 88vw; max-height: 84vh;
  border-radius: 4px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.5);
}
.lightbox-close {
  position: absolute; top: 24px; right: 32px;
  background: none; border: none; color: var(--white);
  font-size: 2.4rem; line-height: 1; cursor: pointer;
}
.lightbox-nav {
  position: absolute; top: 50%; transform: translateY(-50%);
  background: rgba(255,255,255,0.1); border: none; color: var(--white);
  width: 48px; height: 48px; border-radius: 50%;
  font-size: 1.1rem; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background 0.2s ease;
}
.lightbox-nav:hover { background: rgba(255,255,255,0.2); }
.lightbox-prev { left: 24px; }
.lightbox-next { right: 24px; }

@media (max-width: 760px) {
  .gallery-grid { grid-template-columns: 1fr; }
  .lightbox-nav { width: 40px; height: 40px; }
}
