/* ==========================================================================
   Hilsy Villalobos — Legal Consultant, Roatán
   Structure & type scale mirror the wilsonharle.com reference build;
   palette inverted to a light/beige surface per client direction.
   ========================================================================== */

/* ---------- Fonts ---------- */
/* Headings: URW Classico (Hermann Zapf's Optima, URW++ revision) — the exact
   family the reference site loads as "classico-urw" via Adobe Fonts.
   See README for licensing before going live. */
@font-face {
  font-family: "classico-urw";
  src: url("../fonts/URWClassico-Regular.woff2") format("woff2");
  font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "classico-urw";
  src: url("../fonts/URWClassico-Italic.woff2") format("woff2");
  font-weight: 400; font-style: italic; font-display: swap;
}
@font-face {
  font-family: "classico-urw";
  src: url("../fonts/URWClassico-Bold.woff2") format("woff2");
  font-weight: 700; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "classico-urw";
  src: url("../fonts/URWClassico-BoldItalic.woff2") format("woff2");
  font-weight: 700; font-style: italic; font-display: swap;
}

/* Body: DM Sans — same family as the reference. */
@font-face {
  font-family: "DM Sans";
  font-style: normal; font-weight: 100 1000; font-display: swap;
  src: url("../fonts/dmsans-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
    U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193,
    U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "DM Sans";
  font-style: normal; font-weight: 100 1000; font-display: swap;
  src: url("../fonts/dmsans-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF,
    U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020,
    U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "DM Sans";
  font-style: italic; font-weight: 100 1000; font-display: swap;
  src: url("../fonts/dmsans-latin-italic.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
    U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193,
    U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ---------- Tokens ---------- */
:root {
  --body-font: "DM Sans", system-ui, sans-serif;
  --headings: "classico-urw", Optima, "Segoe UI", sans-serif;

  --page: #f6f2ea;          /* main surface — warm paper */
  --band: #ece5d8;          /* nav + footer band */
  --ink: #14110f;           /* body text */
  --ink-soft: #5f584e;      /* secondary text */
  --lines: #14110f26;       /* hairlines */
  --red: #c9272c;           /* brand square */
  --red-hover: #fc0000;     /* hover accent, as on the reference */
}

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

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background-color: var(--page);
  color: var(--ink);
  font-family: var(--body-font);
  font-size: 14px;
  line-height: 20px;
  min-height: 100%;
}

img { max-width: 100%; }

a { color: inherit; }

/* ---------- Layout primitives ---------- */
.section { margin-bottom: 20px; }
.section.header { position: sticky; top: -38px; z-index: 5000; margin-bottom: 0; }
.section.services { margin-bottom: 0; }
.section.footer {
  background-color: var(--band);
  border-top: 1px solid var(--lines);
  margin-top: 60px;
  margin-bottom: 0;
}

.container {
  max-width: 2200px;
  padding-left: 4em;
  padding-right: 4em;
  margin-left: auto;
  margin-right: auto;
}
.container.nav {
  display: flex;
  align-items: flex-end;
  justify-content: flex-start;
  width: 98vw;
  min-height: auto;
  padding-top: 2.6em;
  padding-bottom: 4em;
  background-color: var(--band);
  border-bottom-left-radius: 5px;
  border-bottom-right-radius: 5px;
}
.container.footer-outer {
  display: flex;
  align-items: flex-end;
  justify-content: flex-start;
  min-height: 210px;
  padding-bottom: 3em;
}

/* ---------- Navigation ---------- */
.navbar { display: flex; align-items: flex-end; width: 100%; }

.brand {
  flex: 1;
  margin-bottom: 8px;
  text-decoration: none;
  display: block;
}

/* Wordmark: "HILSY [red square] VILLALOBOS" — mirrors the reference lockup. */
.logo {
  display: flex;
  align-items: center;
  gap: .62em;
  font-family: var(--headings);
  font-size: 22px;
  line-height: 1;
  letter-spacing: .155em;
  text-transform: uppercase;
  color: var(--ink);
  white-space: nowrap;
}
.logo .mark {
  width: .95em;
  height: .95em;
  background-color: var(--red);
  flex: 0 0 auto;
}
.footer .logo { font-size: 18px; }

.nav-menu { display: block; }
.div-block { display: flex; justify-content: flex-end; width: 100%; min-width: 230px; }

.nav-item-holder {
  display: flex;
  align-self: center;
  flex: 0 auto;
  margin-bottom: 5px;
  margin-right: 40px;
}
.nav-item-holder.last { margin-right: 0; }

.nav-link {
  font-family: var(--headings);
  font-size: 14px;
  line-height: 14px;
  color: var(--ink);
  text-decoration: none;
  white-space: nowrap;
  transition: color .525s;
}
.nav-link:hover,
.nav-link.current { color: var(--red-hover); }

.burger {
  display: none;
  position: relative;
  width: 40px;
  height: 26px;
  border: 0;
  background: none;
  padding: 0;
  cursor: pointer;
}
.top-line, .middle-line, .bottom-line {
  position: absolute; left: 0; right: 0;
  width: 40px; height: 2px;
  margin-left: auto; margin-right: auto;
  background-color: var(--ink);
  transition: transform .3s, opacity .3s;
}
.top-line { top: 0; }
.middle-line { top: 8px; }
.bottom-line { top: 16px; }

/* ---------- Type scale ---------- */
h1, h2, h3, h4, h5 { margin: 0; font-weight: 400; }

.h1 {
  font-family: var(--headings);
  font-size: 28px;
  line-height: 38px;
  font-weight: 400;
  color: var(--ink);
}
.h1.black { max-width: 740px; font-size: 40px; line-height: 50px; }

.h2 {
  font-family: var(--headings);
  font-size: 36px;
  line-height: 40px;
  font-weight: 400;
  color: var(--ink);
}
.h2.publications-list { transition: color .4s; }
.h2.publications-list:hover { color: var(--red-hover); }

.h3 {
  font-family: var(--body-font);
  font-size: 16px;
  line-height: 22px;
  font-weight: 300;
  max-width: 350px;
  margin-top: 17px;
  color: var(--ink);
  transition: color .4s;
}
.h3:hover { color: var(--red-hover); }
.h3.contact { max-width: none; margin-top: 50px; }
.h3.contact:hover { color: var(--ink); }

.h4 {
  font-family: var(--body-font);
  font-size: 16px;
  line-height: 16px;
  font-weight: 400;
  color: var(--ink-soft);
}
.h4.bottom-margin { margin-bottom: 30px; }
.h4.bottom-margin.button {
  margin-bottom: 0;
  padding-top: 30px;
  transition: color .5s;
}
.h4.bottom-margin.button:hover { color: var(--red-hover); }
.h4.services { margin-top: 0; margin-bottom: 59px; line-height: 20px; }
.h4.pub-list { margin-bottom: 0; padding-top: 100px; }
[data-year-group]:first-child .h4.pub-list { padding-top: 0; }

.heading {
  font-family: var(--headings);
  font-size: 36px;
  line-height: 38px;
  font-weight: 400;
  margin-top: 10px;
  margin-bottom: 50px;
}
.heading.smaller { font-size: 30px; line-height: 36px; margin-top: 40px; margin-bottom: 18px; }
.small-heading {
  font-family: var(--body-font);
  font-weight: 400;
  font-size: 18px;
  line-height: 24px;
  margin-bottom: 0;
  color: var(--ink-soft);
}

.line {
  background-color: var(--lines);
  align-self: flex-end;
  min-width: 160px;
  height: 1px;
  margin-right: 8px;
}

/* ---------- Home: hero ---------- */
.hero-slider {
  position: relative;
  min-height: 90vh;
  margin-bottom: 145px;
  background-color: var(--band);
  overflow: hidden;
}
.hero-slide {
  position: absolute;
  inset: 0;
  background-position: 50% 28%;
  background-size: cover;
  background-repeat: no-repeat;
  opacity: 0;
  transition: opacity 1.6s ease-in-out;
}
.hero-slide.is-active { opacity: 1; }

/* Scrim keeps the overlaid type legible over any of the three portraits. */
.hero-scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to top,
    rgba(246, 242, 234, .92) 0%,
    rgba(246, 242, 234, .55) 26%,
    rgba(246, 242, 234, 0) 55%
  );
  pointer-events: none;
}

.h1.hero {
  position: absolute;
  left: 0; bottom: 0;
  z-index: 40;
  max-width: 810px;
  margin-bottom: 80px;
  padding-left: 2em;
  font-family: var(--headings);
  font-size: 28px;
  line-height: 38px;
  text-align: left;
}

.hero-name {
  position: absolute;
  right: 4em;
  bottom: 80px;
  z-index: 40;
  display: flex;
  align-items: center;
}
.hero-name .h4 { color: var(--ink); align-self: flex-end; }
.hero-name .h4.name { font-weight: 400; }

.hero-dots {
  position: absolute;
  right: 4em;
  bottom: 44px;
  z-index: 40;
  display: flex;
  gap: 8px;
}
.hero-dot {
  width: 22px; height: 2px;
  border: 0; padding: 0;
  background-color: #14110f40;
  cursor: pointer;
  transition: background-color .4s;
}
.hero-dot.is-active { background-color: var(--red); }

/* ---------- Home: two-column index ---------- */
._2-column {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 30px;
}
.left-column { width: 35%; }
.right-column { width: 60%; }

.service-item { margin-bottom: 0; }
.services-link { text-decoration: none; display: block; }

.publication-item { padding-bottom: 26px; margin-bottom: 26px; border-bottom: 1px solid var(--lines); }
.publication-item:last-child { border-bottom: 0; }
.publication-link { display: block; width: 100%; text-decoration: none; }
.publication-meta {
  font-family: var(--body-font);
  font-size: 13px;
  line-height: 18px;
  font-weight: 400;
  color: var(--ink-soft);
  margin-bottom: 10px;
  letter-spacing: .04em;
  text-transform: uppercase;
}
.view-all { display: inline-block; text-decoration: none; margin-top: 20px; }

/* ---------- Footer ---------- */
.footer {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  width: 100%;
  padding-top: 40px;
  border-top: 1px solid var(--lines);
}
.footer-link { text-decoration: none; }
.copyright {
  font-family: var(--headings);
  font-size: 14px;
  line-height: 20px;
  color: var(--ink-soft);
  text-align: right;
}
.copyright a { color: inherit; text-decoration: none; transition: color .4s; }
.copyright a:hover { color: var(--red-hover); }

/* ---------- About ---------- */
.about-stack {
  display: grid;
  grid-template-columns: .5fr 1.75fr 1.75fr;
  gap: 40px;
  align-items: start;
  justify-content: space-between;
}
.top-line-about { border-bottom: 1px solid var(--lines); margin-bottom: 10px; }
.page-nav { position: sticky; top: 120px; padding-top: 100px; }
.page-nav-link { display: block; width: 100%; text-decoration: none; line-height: 20px; }
.page-nav-item {
  width: 100%;
  margin: 0 0 10px;
  padding: 7px 0 19px;
  border-bottom: 1px solid var(--lines);
  font-family: var(--body-font);
  font-size: 16px;
  font-weight: 300;
  color: var(--ink);
  transition: color .2s;
}
.page-nav-item:hover { color: var(--red-hover); }

.left-page { padding-top: 100px; padding-bottom: 140px; }
.right-page {
  position: sticky;
  top: 120px;
  min-height: 900px;
  margin-top: 100px;
  background-position: 50% 20%;
  background-size: cover;
  background-repeat: no-repeat;
  border-radius: 5px;
}

.about-rtf { font-family: var(--headings); color: var(--ink); }
.about-rtf p { margin: 0 0 20px; font-size: 16px; line-height: 25px; }
.about-rtf ul { margin: 0 0 20px; padding-left: 18px; font-size: 16px; line-height: 25px; }
.about-rtf li { margin-bottom: 6px; }
.about-rtf a { color: var(--ink); font-size: 16px; }

.positions-holder { width: 100%; margin-top: 40px; }
.positions-title {
  padding: 10px 27px 11px 0;
  border-top: 1px solid var(--lines);
  border-bottom: 1px solid var(--lines);
  font-family: var(--headings);
  font-size: 23px;
  line-height: 23px;
  color: var(--ink);
}
.positions-title + .positions-title { border-top: 0; }

/* ---------- Services ---------- */
.services-title {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr 1fr;
  margin-top: 80px;
  margin-bottom: 80px;
}
.services-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr 1fr;
  gap: 16px;
  padding-bottom: 40px;
}
.collection-item { width: 100%; }
.services-title-holder {
  display: block;
  position: relative;
  width: 100%;
  text-decoration: none;
  color: var(--ink);
}
.services-titles {
  position: absolute;
  z-index: 1;
  max-width: 280px;
  margin-left: 24px;
  padding-top: 24px;
  padding-right: 40px;
  font-family: var(--headings);
  font-size: 24px;
  line-height: 30px;
  font-weight: 400;
  color: var(--ink);
}
.services-item-background {
  height: 300px;
  border-radius: 5px;
  opacity: .6;
  transition: opacity .2s;
}
.services-title-holder:hover .services-item-background { opacity: 1; }
.services-blurb {
  margin-top: 14px;
  font-family: var(--body-font);
  font-size: 14px;
  line-height: 20px;
  font-weight: 300;
  color: var(--ink-soft);
}

/* ---------- Publications / Resources ---------- */
.resources-2-col {
  display: flex;
  justify-content: space-between;
  align-items: stretch;
  gap: 100px;
  margin-top: 150px;
}
.resources-left-column { width: 60%; }
.resources-right-column { width: auto; font-family: var(--headings); color: var(--ink); }

.pub-filter { margin-bottom: 0; }
.pub-list { margin-bottom: 0; }
.pub-filter-item {
  display: flex;
  align-items: center;
  gap: 9px;
  height: 31px;
  margin-bottom: 0;
  font-family: var(--body-font);
  font-size: 16px;
  font-weight: 400;
  color: var(--ink);
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
  transition: color .4s;
}
.pub-filter-item:hover,
.pub-filter-item.is-active { color: var(--red-hover); }
.line.pub-filter { flex: 0 0 160px; align-self: center; margin: 0; }
.pub-filter-item { justify-content: flex-start; text-align: left; }
.resources-right-column { width: 26%; min-width: 240px; }

.resources-rtf p { margin: 0 0 18px; }
.resources-rtf a {
  font-family: var(--body-font);
  font-size: 16px;
  font-weight: 300;
  color: var(--ink);
  transition: color .4s;
}
.resources-rtf a:hover { color: var(--red-hover); }

/* ---------- Article ---------- */
.article-columns {
  display: flex;
  justify-content: space-between;
  min-height: 710px;
  margin-top: 80px;
}
.article-holder { width: 70%; }
.article-aside { width: 22%; }
.article-rtf { margin-top: 40px; }
.article-rtf p {
  font-family: var(--body-font);
  margin: 0 0 20px;
  font-size: 16px;
  line-height: 24px;
  font-weight: 300;
}
.article-rtf h2 {
  font-family: var(--body-font);
  margin-top: 40px;
  margin-bottom: 12px;
  font-size: 28px;
  font-weight: 400;
}
.article-rtf ul, .article-rtf ol {
  font-family: var(--body-font);
  margin-bottom: 16px;
  padding-left: 20px;
  font-size: 16px;
  line-height: 24px;
  font-weight: 300;
}
.article-rtf blockquote {
  margin: 0 0 20px;
  padding-left: 16px;
  border-left: 2px solid var(--lines);
  font-style: italic;
}
.article-rtf a { color: var(--ink); }

.print-button {
  display: block;
  max-width: 80px;
  margin-top: 20px;
  margin-left: auto;
  padding: 6px;
  border: 0;
  border-radius: 5px;
  background-color: var(--band);
  color: var(--ink);
  font-family: var(--body-font);
  font-size: 12px;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: color .4s;
}
.print-button:hover { color: var(--red-hover); }

.demo-note {
  font-family: var(--body-font);
  font-size: 13px;
  line-height: 19px;
  font-style: italic;
  color: var(--ink-soft);
  margin-top: 18px;
}

/* ---------- Contact ---------- */
.contact-block {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  margin-top: 150px;
}
.contact-map { text-decoration: none; }
.contact-ph { margin-top: 40px; text-decoration: none; }
.h1.contact-large-link { transition: color .4s; }
.h1.contact-large-link:hover { color: var(--red-hover); }
.contact-small-link {
  display: block;
  color: var(--ink);
  text-decoration: none;
  transition: color .4s;
}
.contact-small-link:hover { color: var(--red-hover); }

/* ---------- Breakpoints (mirroring the reference thresholds) ---------- */
@media screen and (min-width: 1440px) {
  .h1 { font-size: 36px; line-height: 46px; }
  .h1.hero { max-width: 900px; font-size: 36px; line-height: 46px; }
}

@media screen and (max-width: 991px) {
  .container, .container.nav, .container.footer-outer { padding-left: 2em; padding-right: 2em; }
  .container.nav { padding-bottom: 2em; }

  .burger { display: block; margin-left: auto; }
  .nav-menu {
    position: fixed;
    inset: 0;
    z-index: 4000;
    background-color: var(--band);
    transform: translateY(-100%);
    transition: transform .5s ease;
    overflow-y: auto;
  }
  .nav-menu.is-open { transform: translateY(0); }
  .div-block {
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-height: 96vh;
  }
  .nav-item-holder { width: auto; margin-bottom: 10px; margin-right: 0; }
  .nav-link { margin-bottom: 30px; font-size: 36px; }

  .h1.hero { font-size: 28px; line-height: 38px; padding-left: 2em; }
  .hero-name, .hero-dots { right: 2em; }

  ._2-column { flex-wrap: wrap-reverse; }
  .left-column { width: 100%; margin-top: 100px; }
  .right-column { width: 100%; }

  .about-stack { grid-template-columns: 1fr; }
  .page-nav { position: static; padding-top: 40px; }
  .left-page { padding-top: 40px; padding-bottom: 60px; }
  .right-page { position: static; min-height: 460px; margin-top: 0; }

  .services-grid { grid-template-columns: 1fr 1fr; }
  .services-title { grid-template-columns: 1fr; margin-top: 40px; margin-bottom: 40px; }

  .resources-2-col { flex-direction: column; gap: 60px; margin-top: 80px; }
  .resources-left-column, .resources-right-column { width: 100%; }

  .article-columns { flex-direction: column; margin-top: 40px; }
  .article-holder, .article-aside { width: 100%; }

  .footer { flex-direction: column; align-items: center; gap: 22px; }
  .copyright { text-align: center; }
}

@media screen and (max-width: 767px) {
  .h1 { font-size: 26px; line-height: 34px; }
  .h1.hero { font-size: 26px; line-height: 36px; }
  .h1.black { font-size: 30px; line-height: 40px; }
  .nav-link { margin-bottom: 10px; font-size: 26px; line-height: 26px; }
  .heading { font-size: 28px; line-height: 32px; }
  .heading.smaller { font-size: 24px; line-height: 30px; }
  .h2 { font-size: 28px; line-height: 32px; }

  /* Stack the credit line under the headline so the two stop colliding. */
  .line { display: none; }
  .h1.hero { margin-bottom: 116px; }
  .hero-name { left: 2em; right: auto; bottom: 62px; }
  .hero-dots { right: 2em; bottom: 26px; }
}

@media screen and (max-width: 479px) {
  .container, .container.nav, .container.footer-outer { padding-left: 1em; padding-right: 1em; }
  .h1.hero { padding-left: 1em; padding-right: 1em; font-size: 20px; line-height: 27px; margin-bottom: 80px; }
  .logo { font-size: 15px; letter-spacing: .12em; }
  .h1.hero { margin-bottom: 104px; }
  .hero-name { left: 1em; right: auto; bottom: 56px; }
  .hero-dots { right: 1em; bottom: 24px; }
  .services-grid { grid-template-columns: 1fr; }
  .top-line, .middle-line, .bottom-line { width: 30px; height: 1px; }
  .burger { width: 30px; }
}

@media (prefers-reduced-motion: reduce) {
  .hero-slide { transition: none; }
  * { scroll-behavior: auto !important; }
}

@media print {
  .section.header, .section.footer, .print-button, .hero-slider { display: none !important; }
  body { background: #fff; }
}
