/* =========================================================
   Parallel Development — site styles
   Plain CSS, no frameworks. Edit the variables below to
   change colors, fonts and spacing across every page.
   ========================================================= */

:root {
  --navy: #16284d;
  --navy-light: #34497a;
  --gold: #f2b632;
  --gold-dark: #b8862b;
  --gold-light: #f6cc6a;
  --ink: #1f2430;
  --muted: #5b6272;
  --bg: #ffffff;
  --bg-alt: #f5f3ee;
  --line: #e2ded4;

  --font: "Montserrat", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --font-nav: "Helvetica Neue", Helvetica, Arial, system-ui, sans-serif;  /* navbar keeps its original typeface */
  --max: 1100px;
  --gutter: 1.25rem;
}

/* ---------- Reset & base ---------- */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  font-size: 1.2rem; /* single body text size used site-wide */
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg);
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

main { flex: 1 0 auto; }  /* grow to fill, never shrink below content (Safari-safe) */

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

a { color: var(--navy); }
a:hover { color: var(--gold-dark); }

h1, h2, h3 {
  color: var(--navy);
  line-height: 1.2;
  letter-spacing: -0.01em;
  margin: 0 0 0.6em;
}
h1 { font-size: clamp(2rem, 5vw, 3.25rem); }
h2 { font-size: clamp(1.5rem, 3vw, 2rem); }
h3 { font-size: 1.35rem; }

p { margin: 0 0 1em; }

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

/* ---------- Header & navbar ---------- */
.site-header {
  background: var(--bg);
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  z-index: 10;
}

.site-header .container {
  max-width: none;          /* logo and links sit near the window edges */
  padding-left: 50px;
  padding-right: 50px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.75rem 2rem;
  padding-top: 1rem;
  padding-bottom: 1rem;
}

/* Logo (inline SVG — same artwork as images/logo.svg) */
.brand, .brand:hover { display: block; line-height: 0; text-decoration: none; }
.brand svg text { text-decoration: none; }
.brand .logo { height: 96px; width: auto; display: block; }

.site-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1.75rem;
}

.site-nav a {
  font-family: var(--font-nav);
  text-decoration: none;
  color: var(--ink);
  font-size: 0.95rem;
  font-weight: 500;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  padding: 0.25rem 0;
  border-bottom: 2px solid transparent;
}
.site-nav a:hover { color: var(--navy); border-bottom-color: var(--gold); }
.site-nav a[aria-current="page"] { color: var(--navy); border-bottom-color: var(--gold); }

/* ---------- Home page: single full-width photo ---------- */
.home-photo img { width: 100%; height: auto; display: block; }
.home-photo a { display: block; }
/* Desktop: photo fills the window below the 129px navbar with no scrolling,
   trimming the edges as needed. Phones/tablets show the whole photo. */
@media (min-width: 861px) {
  .home-photo img {
    height: calc(100vh - 129px);
    height: calc(100dvh - 129px);
    object-fit: cover;
    object-position: center;
  }
}

.visually-hidden {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* ---------- Buttons ---------- */
.button {
  display: inline-block;
  background: var(--gold);
  color: var(--navy);
  font-weight: 600;
  text-decoration: none;
  padding: 0.8rem 1.6rem;
  border: 2px solid var(--gold);
  margin-top: 0.75rem;
  transition: background 0.15s, color 0.15s;
}
.button:hover { background: transparent; color: var(--gold-light); }
.button-outline { background: transparent; color: var(--navy); border-color: var(--navy); }
.button-outline:hover { background: var(--navy); color: #fff; }

/* ---------- Sections ---------- */
.section { padding: clamp(3rem, 8vw, 5rem) 0; }
.section-alt { background: var(--bg-alt); }

.lead { max-width: 60ch; }

/* ---------- Grids & cards ---------- */
.grid {
  display: grid;
  gap: 2rem;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.card {
  background: var(--bg);
  border: 1px solid var(--line);
  display: flex;
  flex-direction: column;
}
.card-body { padding: 1.5rem; }
.card-body p { margin-bottom: 0.5rem; }
.card-meta {
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gold-dark);
  font-weight: 600;
}

/* Grey box shown until you add real photos */
.placeholder-img {
  aspect-ratio: 4 / 3;
  background: repeating-linear-gradient(45deg, #e9e5db, #e9e5db 12px, #efece4 12px, #efece4 24px);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  font-size: 0.85rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.placeholder-img.portrait { aspect-ratio: 1 / 1; }

.feature {
  border-top: 3px solid var(--gold);
  padding-top: 1.25rem;
}
.feature p { color: var(--muted); }

/* ---------- Two-column layout ---------- */
.split {
  display: grid;
  gap: 3rem;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  align-items: start;
}

/* ---------- Call to action band ---------- */
.cta {
  background: var(--navy);
  color: #fff;
  text-align: center;
  padding: clamp(3rem, 8vw, 4.5rem) 0;
}
.cta h2 { color: #fff; }
.cta p { color: #d8dce6; }

/* ---------- Contact ---------- */
/* Full-width banner image (Contact page) */
.banner img {
  display: block;
  width: 100%;
  height: clamp(160px, 22vw, 300px);
  object-fit: cover;
  object-position: center;
}

.section.contact { padding-top: clamp(2rem, 5vw, 3rem); }
.contact-form { max-width: 640px; margin: 0 auto; }

form { display: grid; gap: 1rem; }
label { font-weight: 600; font-size: 0.9rem; color: var(--navy); }
input, textarea {
  width: 100%;
  font: inherit;
  padding: 0.7rem 0.8rem;
  border: 1px solid var(--line);
  background: #fff;
  margin-top: 0.3rem;
}
input:focus, textarea:focus { outline: 2px solid var(--gold); outline-offset: 0; border-color: var(--gold); }
textarea { min-height: 150px; resize: vertical; }
form .button { justify-self: start; cursor: pointer; font-size: 1rem; }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--navy);
  color: #b9c0d0;
  padding: 1.1rem 0;
  font-size: 0.9rem;
}
.site-footer .container {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1rem;
}
.site-footer .container { max-width: none; padding-left: 50px; padding-right: 50px; }  /* match navbar edges */
@media (max-width: 860px) { .site-footer .container { padding-left: var(--gutter); padding-right: var(--gutter); } }
.site-footer p { margin: 0; }
.site-footer a { color: #b9c0d0; text-decoration: none; }
.site-footer a:hover { color: var(--gold-light); }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 1.25rem; flex-wrap: wrap; }

/* ---------- Photos in cards ---------- */
.card > img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}
.card > img.plan { object-fit: contain; background: #fff; border-bottom: 1px solid var(--line); }

/* ---------- Stat box ---------- */
.stat {
  display: flex;
  align-items: center;
  gap: 1rem;
  background: var(--bg-alt);
  border-left: 4px solid var(--gold);
  padding: 1rem 1.25rem;
  margin: 1.5rem 0;
}
.stat-number { font-size: 2.5rem; font-weight: 300; color: var(--navy); line-height: 1; }
.stat-label {
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 600;
  line-height: 1.5;
}
.section-alt .stat { background: var(--bg); }

/* ---------- Services list ---------- */
.services {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 0.75rem 2rem;
}
.services li { padding-left: 1.1rem; position: relative; }
.services li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.65em;
  width: 6px;
  height: 6px;
  background: var(--gold);
}

/* ---------- About page: photo left, text right ---------- */
/* Photo touches the navbar and footer; the text column carries the padding */
.section.about { padding: 0; }
/* On tall windows, stretch the photo/text row so it reaches the footer.
   (Window height minus the 129px navbar and ~59px footer.) */
@media (min-width: 861px) {
  .about-layout { min-height: calc(100vh - 188px); }
}
.about-text { padding: clamp(1.75rem, 4vw, 2.5rem) 0 clamp(3rem, 8vw, 5rem); }
/* Photo runs flush to the left edge of the window; the text column keeps
   the same right edge as before (a ~72%-wide centered block). */
.about-layout {
  --block: min(max(72vw, 1060px), calc(100vw - 2.5rem));
  --side: calc((100vw - var(--block)) / 2);
  display: grid;
  grid-template-columns: 25vw 1fr;  /* photo = 25% of the window width */
  gap: 3rem;
  align-items: stretch;
  padding-right: var(--side);
}
/* The photo fills the full height of the text column (the text sets the height) */
/* Drawn as a background so it can never extend past its own box (works the same in Safari) */
.about-photo { background: url("../images/about-corridor.jpg") center / cover no-repeat; }
.about-intro { margin: 0; }
.about-intro + .about-intro { margin-top: 1.5rem; }
.about-services { margin-top: 2rem; padding-top: 2rem; border-top: 1px solid var(--line); }
.services-intro { font-weight: 600; color: var(--navy); margin-bottom: 1rem; }

/* Services list: 2 columns (5 / 5) */
.services.services-grid {
  grid-template-columns: 1fr;
  gap: 0.55rem 2rem;
}
@media (min-width: 1101px), (min-width: 761px) and (max-width: 860px) {
  .services.services-grid { grid-template-columns: repeat(2, minmax(0, max-content)); }
}

@media (max-width: 1100px) {
  .about-layout { --block: calc(100vw - 2 * var(--gutter)); }
}
@media (max-width: 860px) {
  .about-layout { grid-template-columns: 1fr; gap: 2rem; padding-right: 0; }
  .about-photo { height: 340px; }
  .about-text { padding: 0 var(--gutter) clamp(3rem, 8vw, 5rem); }
}

/* ---------- Founders strip ---------- */
.founders { display: flex; gap: 1.5rem; flex-wrap: wrap; }
.founders figure { margin: 0; width: 160px; }
.founders img { aspect-ratio: 4 / 5; object-fit: cover; width: 100%; }
.founders figcaption { font-weight: 600; color: var(--navy); margin-top: 0.5rem; }

/* ---------- Projects pages: side nav + 2-column photo tiles ---------- */
.projects-layout {
  display: grid;
  grid-template-columns: 300px 1fr;
  align-items: start;
}

/* Side nav matches the top navbar: same typeface, caps, gold underline on hover/current */
.side-nav {
  position: sticky;
  top: 150px;
  padding: 2.5rem 2rem 2.5rem 50px;
}
.side-nav ul { list-style: none; margin: 0; padding: 0; }
.side-nav li + li { margin-top: 1.1rem; }
.side-nav a {
  font-family: var(--font-nav);
  text-decoration: none;
  color: var(--ink);
  font-size: 0.95rem;
  font-weight: 500;
  letter-spacing: 0.05em;
  line-height: 1.6;
  text-transform: uppercase;
  padding: 0.15rem 0;
  border-bottom: 2px solid transparent;
}
.side-nav a:hover,
.side-nav a[aria-current="page"] { color: var(--navy); border-bottom-color: var(--gold); }

/* Flush 2-column grid of project photos */
.tile-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0;
}
.tile {
  position: relative;
  margin: 0;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: var(--navy);
  outline: none;
}
.tile img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* Title band across the top of each photo */
.tile-caption {
  position: absolute;
  top: 0; left: 0; right: 0;
  z-index: 2;
  padding: 1.1rem 1.5rem 2.75rem;
  background: linear-gradient(to bottom, rgba(22, 40, 77, 0.88) 0%, rgba(22, 40, 77, 0.6) 60%, rgba(22, 40, 77, 0) 100%);
  color: #fff;
}
.tile-loc {
  display: block;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold-light);
}
.tile-title { display: block; font-size: 1.25rem; font-weight: 600; line-height: 1.3; margin-top: 0.2rem; }

/* Description fades in over the photo on hover (or tap/keyboard focus) */
.tile-detail {
  position: absolute;
  inset: 0;
  z-index: 1;
  padding: 6.5rem 1.5rem 1.5rem;
  background: rgba(22, 40, 77, 0.9);
  color: #fff;
  opacity: 0;
  transition: opacity 0.25s ease;
  overflow: auto;
}
.tile-detail p { margin: 0; font-size: 1rem; line-height: 1.6; }
.tile:hover .tile-detail,
.tile:focus .tile-detail,
.tile:focus-within .tile-detail { opacity: 1; }
.tile:hover .tile-caption,
.tile:focus .tile-caption { background: transparent; }

@media (max-width: 1240px) {
  .tile-grid { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .tile { aspect-ratio: 4 / 5; }
  .tile-detail { padding: 6rem 1.25rem 1.25rem; }
  .tile-detail p { font-size: 0.95rem; }
}
@media (max-width: 860px) {
  .projects-layout { grid-template-columns: 1fr; }
  .side-nav { position: static; padding: 1.5rem var(--gutter); }
  .side-nav ul { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.5rem 1.5rem; }
  .side-nav li + li { margin-top: 0; }
}

/* ---------- Team page ---------- */
/* Bios stacked (Laura first), spanning the window with ~50px side padding */
.container.team-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 3.5rem;
  max-width: none;
  padding: 0 50px;
}
.person + .person { padding-top: 3.5rem; border-top: 1px solid var(--line); }
.person::after { content: ""; display: block; clear: both; }
.person-photo { width: 230px; margin: 0.35rem 0 0.75rem; }
.person-left  .person-photo { float: left;  margin-right: 2rem; }
.person-right .person-photo { float: right; margin-left: 2rem; }
.person-photo img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; }
.person-photo .stat { margin: 0.75rem 0 0; padding: 0.75rem 1rem; gap: 0.75rem; }
.person-photo .stat-number { font-size: 2.1rem; }
.person-photo .stat-label { font-size: 0.68rem; letter-spacing: 0.1em; }
.person h2 { margin-bottom: 0.2em; }
.person .role { color: var(--gold-dark); font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; font-size: 0.85rem; margin-bottom: 1.25rem; }

@media (max-width: 640px) {
  .container.team-grid { padding: 0 var(--gutter); }
}

/* ---------- Small screens ---------- */
/* When the logo and links no longer fit on one line, center them stacked */
@media (max-width: 860px) {
  .site-header .container { justify-content: center; text-align: center; padding-left: var(--gutter); padding-right: var(--gutter); }
  .site-nav ul { justify-content: center; gap: 0.25rem 1.25rem; }
}
@media (max-width: 640px) {
  .site-header { position: static; }
  .brand .logo { height: 78px; }
  .person-photo { width: 140px; }
  .person-photo .stat { flex-direction: column; align-items: flex-start; gap: 0.3rem; }
}
