/* ==========================================================================
   Ocean Architects — shared stylesheet
   Nautical palette pulled from the logo: navy, red, ocean blue.
   ========================================================================== */

:root {
  --navy:        #16283f;
  --navy-2:      #1f3350;
  --ink:         #0f1c2e;
  --red:         #c62828;
  --red-dark:    #9e1f1f;
  --blue:        #1f78c8;
  --blue-2:      #2f9adf;
  --sky:         #eaf2fa;
  --paper:       #f7f8fa;
  --white:       #ffffff;
  --muted:       #5b6b7d;
  --line:        #e2e7ee;
  --shadow:      0 10px 30px rgba(16, 40, 63, 0.12);
  --shadow-sm:   0 4px 14px rgba(16, 40, 63, 0.10);
  --radius:      14px;
  --max:         1180px;
  --font:        "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  --serif:       Georgia, "Times New Roman", serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--white);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }

a { color: var(--blue); text-decoration: none; }
a:hover { color: var(--red); }

h1, h2, h3 { font-family: var(--serif); color: var(--navy); line-height: 1.2; margin: 0 0 .5em; }
h1 { font-size: clamp(2rem, 4vw, 3.1rem); letter-spacing: .5px; }
h2 { font-size: clamp(1.5rem, 2.6vw, 2.1rem); }
h3 { font-size: 1.2rem; }

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

.section { padding: 76px 0; }
.section--tint { background: var(--paper); }
.section--navy { background: var(--navy); color: #dbe4ee; }
.section--navy h2, .section--navy h3 { color: #fff; }

.eyebrow {
  display: inline-block;
  font-family: var(--font);
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: var(--red);
  margin-bottom: 10px;
}
.section-head { max-width: 720px; margin: 0 auto 46px; text-align: center; }
.section-head p { color: var(--muted); font-size: 1.05rem; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  padding: 13px 26px;
  border-radius: 40px;
  font-weight: 600;
  font-size: .95rem;
  letter-spacing: .3px;
  cursor: pointer;
  border: 2px solid transparent;
  transition: transform .15s ease, background .2s ease, color .2s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn--red   { background: var(--red); color: #fff; }
.btn--red:hover { background: var(--red-dark); color: #fff; }
.btn--ghost { background: transparent; color: #fff; border-color: rgba(255,255,255,.6); }
.btn--ghost:hover { background: #fff; color: var(--navy); }
.btn--navy  { background: var(--navy); color: #fff; }
.btn--navy:hover { background: var(--navy-2); color:#fff; }

/* ---------- Header / nav ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,.96);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.nav {
  display: flex; align-items: center; justify-content: space-between;
  height: 74px;
}
.nav__brand { display: flex; align-items: center; gap: 12px; }
.nav__brand img { height: 52px; width: auto; }
.nav__brand .brand-text { font-family: var(--serif); font-weight: 700; color: var(--navy); font-size: 1.7rem; line-height: 1; letter-spacing: .3px; }
@media (max-width: 480px){ .nav__brand .brand-text { font-size: 1.3rem; } }
.nav__links { display: flex; align-items: center; gap: 30px; list-style: none; margin: 0; padding: 0; }
.nav__links a { color: var(--navy); font-weight: 600; font-size: .96rem; padding: 6px 0; position: relative; }
.nav__links a::after {
  content:""; position:absolute; left:0; bottom:-2px; height:2px; width:0; background: var(--red); transition: width .2s ease;
}
.nav__links a:hover::after, .nav__links a.active::after { width:100%; }
.nav__links a.active { color: var(--red); }
.nav__toggle { display:none; background:none; border:0; cursor:pointer; padding:8px; }
.nav__toggle span { display:block; width:24px; height:2px; background: var(--navy); margin:5px 0; transition: .2s; }

@media (max-width: 860px) {
  .nav__toggle { display:block; }
  .nav__links {
    position: absolute; top: 74px; left:0; right:0;
    flex-direction: column; gap: 0; background:#fff;
    border-bottom: 1px solid var(--line);
    max-height: 0; overflow: hidden; transition: max-height .28s ease;
  }
  .nav__links.open { max-height: 340px; }
  .nav__links li { width:100%; text-align:center; }
  .nav__links a { display:block; padding: 15px; border-top: 1px solid var(--line); }
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 78vh;
  display: flex; align-items: center;
  color: #fff;
  background: linear-gradient(120deg, rgba(15,28,46,.86), rgba(31,120,200,.55)), var(--hero-img, linear-gradient(120deg,#16283f,#1f78c8));
  background-size: cover; background-position: center;
}
.hero__inner { max-width: 720px; }
.hero h1 { color:#fff; }
.hero p { font-size: 1.15rem; color: #e6edf5; max-width: 600px; }
.hero .btns { margin-top: 26px; display:flex; gap:14px; flex-wrap:wrap; }

.page-hero {
  background: linear-gradient(120deg, rgba(15,28,46,.92), rgba(31,120,200,.72));
  color:#fff; padding: 70px 0 60px; text-align:center;
}
.page-hero h1 { color:#fff; margin-bottom:.2em; }
.page-hero p { color:#e2ebf4; max-width:640px; margin:0 auto; }
.breadcrumb { font-size:.85rem; color:#b9c8d8; margin-top:14px; }
.breadcrumb a { color:#fff; }

/* ---------- Image with fallback placeholder ---------- */
.img-frame { position: relative; overflow: hidden; background: var(--sky); min-height:180px; }
.img-frame img { position: relative; z-index:1; width:100%; height:100%; object-fit: cover; }
.ph {
  position:absolute; inset:0; z-index:0;
  display:flex; align-items:center; justify-content:center; flex-direction:column;
  width:100%; height:100%; min-height:180px;
  background: repeating-linear-gradient(135deg, #e9f0f8 0 14px, #e0eaf4 14px 28px);
  color: var(--navy); text-align:center; gap:6px; padding:16px;
}
.ph svg { width:42px; height:42px; opacity:.5; }
.ph small { font-size:.72rem; color: var(--muted); letter-spacing:.5px; }

/* ---------- Services grid ---------- */
.grid { display:grid; gap: 24px; }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--2 { grid-template-columns: repeat(2, 1fr); }
@media (max-width: 900px){ .grid--3 { grid-template-columns: repeat(2,1fr);} }
@media (max-width: 620px){ .grid--3, .grid--2 { grid-template-columns: 1fr; } }

.card {
  background:#fff; border:1px solid var(--line); border-radius: var(--radius);
  overflow:hidden; box-shadow: var(--shadow-sm); transition: transform .18s ease, box-shadow .18s ease;
}
.card:hover { transform: translateY(-5px); box-shadow: var(--shadow); }
.card__body { padding: 22px; }
.card__body h3 { margin-bottom: 8px; }
.card__body p { color: var(--muted); margin:0; font-size:.96rem; }
.card__icon {
  width:52px; height:52px; border-radius:12px; display:flex; align-items:center; justify-content:center;
  background: var(--sky); color: var(--blue); margin-bottom:14px;
}
.card__icon svg { width:26px; height:26px; }
.card .img-frame { aspect-ratio: 16/10; }

/* ---------- Projects carousel (swipe) ---------- */
.carousel { position: relative; }
.carousel__track {
  display: flex; gap: 24px;
  overflow-x: auto; scroll-snap-type: x mandatory;
  scroll-behavior: smooth; padding: 8px 4px 22px;
  -ms-overflow-style: none; scrollbar-width: none;
}
.carousel__track::-webkit-scrollbar { display: none; }
.slide {
  scroll-snap-align: center; flex: 0 0 clamp(280px, 82%, 760px);
}
.project-card {
  background:#fff; border-radius: var(--radius); overflow:hidden;
  box-shadow: var(--shadow); border:1px solid var(--line);
  display:grid; grid-template-columns: 1.15fr 1fr;
}
.project-card .img-frame { aspect-ratio: auto; min-height: 320px; }
.project-card__body { padding: 30px; display:flex; flex-direction:column; justify-content:center; }
.project-card__body .eyebrow { margin-bottom:6px; }
.project-card__body h3 { font-size: 1.55rem; }
.project-card__body ul { padding-left: 18px; margin: 10px 0 20px; color: var(--muted); }
.project-card__body ul li { margin-bottom: 4px; }
@media (max-width: 720px){
  .project-card { grid-template-columns: 1fr; }
  .project-card .img-frame { min-height: 220px; }
}

.carousel__btns { display:flex; gap:12px; justify-content:center; margin-top: 8px; }
.carousel__btn {
  width:46px; height:46px; border-radius:50%; border:2px solid var(--line);
  background:#fff; color: var(--navy); cursor:pointer; font-size:1.1rem;
  display:flex; align-items:center; justify-content:center; transition:.15s;
}
.carousel__btn:hover { background: var(--navy); color:#fff; border-color: var(--navy); }
.carousel__dots { display:flex; gap:8px; justify-content:center; margin-top:16px; }
.carousel__dots button { width:10px; height:10px; border-radius:50%; border:0; background: var(--line); cursor:pointer; padding:0; transition:.15s; }
.carousel__dots button.active { background: var(--red); width: 26px; border-radius: 6px; }

/* ---------- News ---------- */
.news-item {
  display:flex; gap:20px; align-items:flex-start;
  background:#fff; border:1px solid var(--line); border-radius: var(--radius);
  padding: 22px; box-shadow: var(--shadow-sm); margin-bottom:18px;
}
.news-item .tag {
  flex:0 0 auto; background: var(--sky); color: var(--blue);
  border-radius:10px; padding:10px 12px; font-weight:700; text-align:center; min-width:64px;
}
.news-item h3 { margin-bottom:6px; }
.news-item p { margin:0; color: var(--muted); }

/* ---------- Contact / footer ---------- */
.contact-band { background: linear-gradient(120deg, var(--navy), var(--blue)); color:#fff; text-align:center; padding: 54px 0; }
.contact-band h2 { color:#fff; }
.contact-band a.btn--ghost { border-color:#fff; }

.site-footer { background: var(--ink); color:#aebccb; padding: 54px 0 26px; }
.site-footer a { color:#cdd9e6; }
.footer-grid { display:grid; grid-template-columns: 2fr 1fr 1fr; gap: 40px; align-items: start; }
.site-footer .brand-text { color:#fff; font-family:var(--serif); font-size:1.2rem; }
.site-footer h4 { color:#fff; font-size:.85rem; letter-spacing:2px; text-transform:uppercase; margin-bottom:14px; }
.site-footer ul { list-style:none; padding:0; margin:0; }
.site-footer li { margin-bottom:9px; }
.footer-bottom { border-top:1px solid rgba(255,255,255,.12); margin-top:36px; padding-top:20px; font-size:.85rem; text-align:center; color:#7f92a5; }
@media (max-width: 720px){ .footer-grid { grid-template-columns: 1fr; gap:26px; } }

/* ---------- Utility ---------- */
.center { text-align:center; }
.mt-32 { margin-top: 32px; }
.lead { font-size: 1.12rem; color: var(--muted); }
.contact-list { list-style:none; padding:0; margin: 18px 0 0; }
.contact-list li { margin-bottom:12px; display:flex; gap:12px; align-items:center; }
.contact-list svg { width:20px; height:20px; color: var(--red); flex:0 0 auto; }

/* ---------- Projects page (JS-rendered) ---------- */
.proj-section { margin-bottom: 60px; scroll-margin-top: 90px; }
.proj-top {
  display:grid; grid-template-columns: 1.15fr 1fr; gap:0;
  background:#fff; border:1px solid var(--line); border-radius:var(--radius);
  overflow:hidden; box-shadow:var(--shadow-sm);
}
.proj-top .img-frame { min-height: 340px; cursor: zoom-in; }
.proj-top .body { padding: 34px; display:flex; flex-direction:column; justify-content:center; }
.proj-top .body h3 { font-size: 1.6rem; }
.proj-spec { list-style:none; padding:0; margin:14px 0 0; }
.proj-spec li { display:flex; justify-content:space-between; gap:12px; padding:9px 0; border-bottom:1px dashed var(--line); font-size:.95rem; }
.proj-spec li span:first-child { color:var(--muted); }
.proj-spec li span:last-child { font-weight:600; color:var(--navy); text-align:right; }
@media (max-width:760px){ .proj-top { grid-template-columns:1fr; } .proj-top .img-frame { min-height: 240px; } }

.proj-gallery { display:grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap:12px; margin-top:16px; }
.proj-gallery .img-frame { aspect-ratio: 4/3; border-radius:10px; min-height:0; cursor: zoom-in; }
.proj-video { margin-top:16px; }
.proj-video video { width:100%; border-radius:var(--radius); background:#000; box-shadow:var(--shadow-sm); }

/* ---------- Lightbox ---------- */
.lightbox {
  position: fixed; inset:0; z-index:999; display:none;
  align-items:center; justify-content:center; padding:24px;
  background: rgba(9,18,30,.92);
}
.lightbox.open { display:flex; }
.lightbox img { max-width:92vw; max-height:88vh; border-radius:8px; box-shadow:0 20px 60px rgba(0,0,0,.5); }
.lightbox__close {
  position:absolute; top:18px; right:24px; width:46px; height:46px; border-radius:50%;
  background:rgba(255,255,255,.12); color:#fff; border:0; font-size:1.6rem; cursor:pointer;
}
.lightbox__close:hover { background:rgba(255,255,255,.25); }
.lightbox__nav {
  position:absolute; top:50%; transform:translateY(-50%); width:52px; height:52px; border-radius:50%;
  background:rgba(255,255,255,.12); color:#fff; border:0; font-size:1.6rem; cursor:pointer;
}
.lightbox__nav:hover { background:rgba(255,255,255,.25); }
.lightbox__nav--prev { left:20px; }
.lightbox__nav--next { right:20px; }

/* ---------- Contact form ---------- */
.contact-layout { display:grid; grid-template-columns: 1fr 1.2fr; gap:44px; align-items:start; }
@media (max-width:820px){ .contact-layout { grid-template-columns:1fr; gap:32px; } }
.form-field { margin-bottom:18px; }
.form-field label { display:block; font-weight:600; color:var(--navy); margin-bottom:6px; font-size:.92rem; }
.form-field input, .form-field textarea {
  width:100%; padding:13px 15px; border:1px solid var(--line); border-radius:10px;
  font-family:inherit; font-size:1rem; color:var(--ink); background:#fff; transition:border .15s;
}
.form-field input:focus, .form-field textarea:focus { outline:none; border-color:var(--blue); box-shadow:0 0 0 3px rgba(31,120,200,.12); }
.form-field textarea { min-height:150px; resize:vertical; }
.form-note { font-size:.85rem; color:var(--muted); margin-top:10px; }
.info-card { background:var(--paper); border:1px solid var(--line); border-radius:var(--radius); padding:28px; }
.info-card h3 { margin-bottom:16px; }
