/* Pinheiro & Co LLC — site styles */

@font-face {
  font-family: "Libre Caslon Display";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("fonts/libre-caslon-display-latin-400-normal.woff2") format("woff2");
}

@font-face {
  font-family: "Libre Caslon Text";
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url("fonts/libre-caslon-text-latin-400-italic.woff2") format("woff2");
}

@font-face {
  font-family: "Albert Sans";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("fonts/albert-sans-latin-wght-normal.woff2") format("woff2");
}

:root {
  --white: #ffffff;
  --mist: #eef2f5;
  --navy: #16324a;
  --navy-deep: #0e2334;
  --ink: #1b2733;
  --slate: #556575;
  --line: #d5dde4;
  --oak: #9c6328;
  --honey: #e0b27a;

  --display: "Libre Caslon Display", "Libre Caslon Text", Georgia, "Times New Roman", serif;
  --sans: "Albert Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

  --wrap: 70rem;
  --gutter: 1.5rem;
  --section: clamp(4rem, 9vw, 7rem);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 5.5rem;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--white);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

h1,
h2,
h3 {
  margin: 0;
  color: var(--navy);
  text-wrap: balance;
}

h1,
h2 {
  font-family: var(--display);
  font-weight: 400;
  line-height: 1.06;
}

h2 {
  font-size: clamp(2.25rem, 4.6vw, 3.25rem);
}

h3 {
  font-family: var(--sans);
  font-size: 1.0625rem;
  font-weight: 650;
  line-height: 1.35;
}

p,
dl,
dd,
ul,
address {
  margin: 0;
}

ul {
  padding: 0;
  list-style: none;
}

address {
  font-style: normal;
}

a {
  color: inherit;
}

:focus-visible {
  outline: 2px solid var(--oak);
  outline-offset: 3px;
}

.on-navy :focus-visible {
  outline-color: var(--honey);
}

.wrap {
  width: min(100% - 2 * var(--gutter), var(--wrap));
  margin-inline: auto;
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -4rem;
  z-index: 100;
  padding: 0.6rem 1rem;
  background: var(--navy);
  color: var(--white);
  text-decoration: none;
}

.skip-link:focus {
  top: 1rem;
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.875rem;
  padding: 0.7rem 1.5rem;
  border: 1px solid transparent;
  border-radius: 2px;
  font-family: var(--sans);
  font-size: 0.9375rem;
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.btn-primary {
  background: var(--navy);
  color: var(--white);
}

.btn-primary:hover {
  background: var(--navy-deep);
}

.btn-honey {
  background: var(--honey);
  color: var(--navy-deep);
}

.btn-honey:hover {
  background: #ebc595;
}

.btn-outline {
  border-color: rgba(255, 255, 255, 0.6);
  color: var(--white);
}

.btn-outline:hover {
  border-color: var(--white);
  background: rgba(255, 255, 255, 0.1);
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--white);
  border-bottom: 1px solid var(--line);
}

.header-inner {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  min-height: 4.5rem;
}

.brand {
  color: var(--navy);
  font-family: var(--display);
  font-size: 1.625rem;
  line-height: 1;
  text-decoration: none;
  white-space: nowrap;
}

.brand-amp {
  padding-inline: 0.04em;
  color: var(--oak);
  font-family: "Libre Caslon Text", Georgia, serif;
  font-style: italic;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 2rem;
}

.nav-link {
  color: var(--slate);
  font-size: 0.9375rem;
  font-weight: 500;
  text-decoration: none;
}

.nav-link:hover {
  color: var(--navy);
}

.nav-toggle {
  display: none;
  align-items: center;
  min-height: 2.75rem;
  padding: 0.5rem 0.9rem;
  border: 1px solid var(--line);
  border-radius: 2px;
  background: var(--white);
  color: var(--navy);
  font-family: var(--sans);
  font-size: 0.9375rem;
  font-weight: 600;
  cursor: pointer;
}

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

.hero {
  display: grid;
  grid-template-columns:
    minmax(var(--gutter), 1fr)
    minmax(0, calc(var(--wrap) / 2))
    minmax(0, calc(var(--wrap) / 2))
    minmax(var(--gutter), 1fr);
  min-height: min(43rem, 86vh);
  background: var(--navy);
  color: var(--white);
}

.hero-text {
  grid-column: 2;
  align-self: center;
  padding-block: clamp(3.5rem, 8vw, 6rem);
  padding-right: clamp(1.5rem, 4vw, 4rem);
}

.hero h1 {
  color: var(--white);
  font-size: clamp(2.75rem, 5.7vw, 4.625rem);
  line-height: 1;
  letter-spacing: -0.005em;
}

.hero-lede {
  max-width: 31rem;
  margin-top: 1.75rem;
  color: rgba(255, 255, 255, 0.88);
  font-size: clamp(1.0625rem, 1.4vw, 1.1875rem);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 2.25rem;
}

.hero-photo {
  position: relative;
  grid-column: 3 / 5;
  min-height: 22rem;
  background: var(--mist);
}

.hero-photo img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 50%;
}

@media (prefers-reduced-motion: no-preference) {
  .hero-photo img {
    animation: settle 1.1s cubic-bezier(0.2, 0.7, 0.2, 1) both;
  }
}

@keyframes settle {
  from {
    opacity: 0;
    transform: scale(1.04);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.hero-photo {
  overflow: hidden;
}

/* Company facts ---------------------------------------------------------- */

.facts {
  border-bottom: 1px solid var(--line);
}

.facts-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1.5fr 1fr;
  gap: 2rem;
  padding-block: 2.5rem;
}

.fact dt {
  color: var(--slate);
  font-size: 0.875rem;
  font-weight: 500;
}

.fact dd {
  margin-top: 0.3rem;
  color: var(--navy);
  font-family: var(--display);
  font-size: 1.5rem;
  line-height: 1.2;
}

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

.section {
  padding-block: var(--section);
}

.section-tint {
  background: var(--mist);
}

.section-intro {
  max-width: 34rem;
  margin-top: 1.25rem;
  color: var(--slate);
}

/* About ------------------------------------------------------------------ */

.about-head {
  display: grid;
  grid-template-columns: 5fr 7fr;
  gap: clamp(2rem, 6vw, 5rem);
  align-items: start;
}

.about-copy p + p {
  margin-top: 1.1rem;
}

.about-copy p:first-child {
  font-size: 1.1875rem;
  line-height: 1.55;
}

.principles {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2rem;
  margin-top: clamp(3rem, 6vw, 4.5rem);
}

.principle {
  padding-top: 1.25rem;
  border-top: 2px solid var(--navy);
}

.principle p {
  margin-top: 0.5rem;
  color: var(--slate);
  font-size: 1rem;
}

/* What we do ------------------------------------------------------------- */

.services-grid {
  display: grid;
  grid-template-columns: 4fr 8fr;
  gap: clamp(2rem, 6vw, 5rem);
  align-items: start;
}

.service {
  display: grid;
  grid-template-columns: 15rem 1fr;
  gap: 1.5rem;
  align-items: baseline;
  padding-block: 1.6rem;
  border-top: 1px solid #c3ced8;
}

.service:last-child {
  border-bottom: 1px solid #c3ced8;
}

.service dt {
  color: var(--navy);
  font-family: var(--display);
  font-size: 1.5rem;
  line-height: 1.2;
}

.service dd {
  color: var(--slate);
}

/* Question band ---------------------------------------------------------- */

.band {
  background: var(--navy);
  color: var(--white);
}

.band-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem 2rem;
  padding-block: clamp(2.75rem, 6vw, 4rem);
}

.band h2 {
  color: var(--white);
  font-size: clamp(1.875rem, 3.6vw, 2.625rem);
}

/* Contact ---------------------------------------------------------------- */

.contact-grid {
  display: grid;
  grid-template-columns: 5fr 6fr;
  gap: clamp(2.5rem, 6vw, 5.5rem);
  align-items: start;
}

.contact-list {
  margin-top: 2.25rem;
}

.contact-item {
  display: grid;
  grid-template-columns: 8.5rem 1fr;
  gap: 1rem;
  padding-block: 1rem;
  border-top: 1px solid var(--line);
}

.contact-item:last-child {
  border-bottom: 1px solid var(--line);
}

.contact-item dt {
  color: var(--slate);
  font-size: 0.9375rem;
}

.contact-item dd {
  color: var(--ink);
  font-weight: 500;
}

.contact-item a {
  text-decoration-color: var(--line);
  text-underline-offset: 0.2em;
}

.contact-item a:hover {
  color: var(--oak);
  text-decoration-color: currentColor;
}

.contact-form {
  padding: clamp(1.5rem, 3.5vw, 2.5rem);
  border-top: 3px solid var(--navy);
  background: var(--mist);
}

.field + .field {
  margin-top: 1.25rem;
}

.field label {
  display: block;
  margin-bottom: 0.4rem;
  font-size: 0.9375rem;
  font-weight: 600;
}

.field input,
.field textarea {
  display: block;
  width: 100%;
  padding: 0.75rem 0.9rem;
  border: 1px solid #b4c0cb;
  border-radius: 2px;
  background: var(--white);
  color: var(--ink);
  font: inherit;
}

.field textarea {
  min-height: 9rem;
  resize: vertical;
}

.field input:focus,
.field textarea:focus {
  outline: 2px solid var(--navy);
  outline-offset: 1px;
  border-color: var(--navy);
}

.contact-form .btn {
  width: 100%;
  margin-top: 1.5rem;
}

.form-note {
  margin-top: 0.9rem;
  color: var(--slate);
  font-size: 0.875rem;
}

.form-status {
  margin-top: 0.9rem;
  color: var(--navy);
  font-size: 0.9375rem;
  font-weight: 600;
}

.form-status:empty {
  display: none;
}

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

.site-footer {
  background: var(--navy-deep);
  color: rgba(255, 255, 255, 0.76);
  font-size: 0.9375rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1.4fr;
  gap: 2.5rem;
  padding-block: 4rem 3rem;
}

.footer-brand {
  color: var(--white);
  font-family: var(--display);
  font-size: 1.5rem;
  line-height: 1.1;
}

.footer-brand .brand-amp {
  color: var(--honey);
}

.footer-about {
  max-width: 22rem;
  margin-top: 0.9rem;
}

.footer-heading {
  color: var(--white);
  font-family: var(--sans);
  font-size: 0.9375rem;
  font-weight: 600;
  line-height: 1.6;
}

.footer-list {
  margin-top: 0.8rem;
}

.footer-list li + li {
  margin-top: 0.45rem;
}

.footer-list a {
  text-decoration: none;
}

.footer-list a:hover {
  color: var(--honey);
  text-decoration: underline;
  text-underline-offset: 0.2em;
}

.footer-legal {
  padding-block: 1.5rem 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.16);
  color: rgba(255, 255, 255, 0.68);
  font-size: 0.875rem;
}

.footer-legal p + p {
  margin-top: 0.25rem;
}

/* Legal and plain pages -------------------------------------------------- */

.page-head {
  padding-block: clamp(3rem, 7vw, 5rem) clamp(2rem, 4vw, 3rem);
  background: var(--navy);
  color: rgba(255, 255, 255, 0.82);
}

.page-head h1 {
  color: var(--white);
  font-size: clamp(2.5rem, 5.5vw, 3.75rem);
}

.page-head p {
  margin-top: 0.75rem;
}

.prose {
  max-width: 44rem;
  padding-block: clamp(2.5rem, 6vw, 4rem) var(--section);
}

.prose h2 {
  margin-top: 2.75rem;
  font-size: 1.875rem;
  line-height: 1.15;
}

.prose > :first-child {
  margin-top: 0;
}

.prose p,
.prose ul,
.prose address {
  margin-top: 1rem;
}

.prose ul {
  padding-left: 1.25rem;
  list-style: disc;
}

.prose li + li {
  margin-top: 0.5rem;
}

.prose a {
  color: var(--navy);
  text-underline-offset: 0.2em;
}

.prose a:hover {
  color: var(--oak);
}

.notfound {
  padding-block: clamp(5rem, 14vw, 10rem);
}

.notfound h1 {
  font-size: clamp(2.5rem, 5.5vw, 3.75rem);
}

.notfound p {
  max-width: 34rem;
  margin-top: 1rem;
  color: var(--slate);
}

.notfound .btn {
  margin-top: 2rem;
}

/* Smaller screens -------------------------------------------------------- */

@media (max-width: 60rem) {
  .facts-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .about-head,
  .services-grid,
  .contact-grid {
    grid-template-columns: 1fr;
  }

  .principles {
    grid-template-columns: repeat(2, 1fr);
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 50rem) {
  .nav-toggle {
    display: inline-flex;
  }

  .site-nav {
    position: absolute;
    top: 100%;
    left: calc(-1 * var(--gutter));
    right: calc(-1 * var(--gutter));
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 0.5rem var(--gutter) 1.5rem;
    border-bottom: 1px solid var(--line);
    background: var(--white);
  }

  .site-nav.is-open {
    display: flex;
  }

  .nav-link {
    padding-block: 0.85rem;
    border-bottom: 1px solid var(--line);
    font-size: 1.0625rem;
  }

  .site-nav .btn {
    margin-top: 1.25rem;
  }

  .hero {
    grid-template-columns: minmax(0, 1fr);
    min-height: 0;
  }

  .hero-text {
    grid-column: 1;
    padding-inline: var(--gutter);
  }

  .hero-photo {
    grid-column: 1;
    min-height: 0;
    aspect-ratio: 4 / 3;
  }

  .service {
    grid-template-columns: 1fr;
    gap: 0.4rem;
  }
}

@media (max-width: 34rem) {
  .facts-grid,
  .principles {
    grid-template-columns: 1fr;
  }

  .facts-grid {
    gap: 1.5rem;
  }

  .contact-item {
    grid-template-columns: 1fr;
    gap: 0.15rem;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .hero-actions .btn {
    flex: 1 1 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .btn {
    transition: none;
  }
}
