
:root {
  --bg: #f4f1eb;
  --paper: #fbfaf7;
  --ink: #1e1e1b;
  --muted: #706e68;
  --line: rgba(30, 30, 27, 0.17);
  --accent: #8b7358;
  --dark: #20231f;
  --serif: "Italiana", Georgia, serif;
  --sans: "DM Sans", Arial, sans-serif;
  --container: min(92vw, 1440px);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-weight: 400;
  line-height: 1.5;
  overflow-x: hidden;
}
body.no-scroll { overflow: hidden; }
img { display: block; width: 100%; }
a { color: inherit; text-decoration: none; }
button { color: inherit; font: inherit; }
::selection { background: var(--dark); color: var(--paper); }

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}
.container { width: var(--container); margin-inline: auto; }
.section-pad { padding: clamp(6rem, 10vw, 11rem) 0; }
.eyebrow {
  margin: 0;
  font-size: .69rem;
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
}
.section-number { display: inline-block; margin-bottom: 1.2rem; color: var(--muted); font-size: .72rem; }
.display-title {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(2.7rem, 6vw, 6.5rem);
  font-weight: 400;
  line-height: .98;
  letter-spacing: -.035em;
}
.display-title em, .hero__title em, .contact h2 em { color: var(--accent); font-style: italic; }

.preloader {
  position: fixed; inset: 0; z-index: 9999;
  display: grid; place-items: center;
  background: var(--paper);
  transition: opacity .7s ease, visibility .7s ease;
}
.preloader.is-hidden { opacity: 0; visibility: hidden; pointer-events: none; }
.preloader__brand { display: grid; place-items: center; }
.preloader__logo { display: block; width: min(58vw, 440px); height: auto; }
.preloader__line { position: absolute; bottom: 14%; width: 120px; height: 1px; overflow: hidden; background: #ddd8cf; }
.preloader__line span { display: block; width: 100%; height: 100%; background: var(--ink); transform: translateX(-100%); animation: preload 1.2s ease forwards; }
@keyframes preload { to { transform: translateX(0); } }

.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 100;
  height: 84px; padding: 0 4vw;
  display: flex; align-items: center; justify-content: space-between;
  border-bottom: 1px solid transparent;
  transition: height .35s ease, background .35s ease, border-color .35s ease;
}
.site-header.is-scrolled { height: 68px; background: rgba(244,241,235,.9); border-color: var(--line); backdrop-filter: blur(16px); }
.brand { display: inline-flex; flex-direction: column; align-items: center; gap: 0; line-height: 1; z-index: 102; }
.brand--logo { align-items: flex-start; }
.brand__logo { display: block; width: clamp(120px, 11vw, 178px); height: auto; }
.brand__name { font-family: var(--serif); font-size: 1.45rem; letter-spacing: .08em; }
.brand__tag { margin-top: .28rem; font-size: .48rem; font-weight: 600; letter-spacing: .38em; }
.main-nav { display: flex; gap: 2.5rem; font-size: .73rem; text-transform: uppercase; letter-spacing: .12em; }
.main-nav a { position: relative; }
.main-nav a::after { content: ""; position: absolute; left: 0; bottom: -.45rem; width: 100%; height: 1px; background: currentColor; transform: scaleX(0); transform-origin: right; transition: transform .3s ease; }
.main-nav a:hover::after { transform: scaleX(1); transform-origin: left; }
.header-cta { display: flex; gap: 1rem; align-items: center; padding: .8rem 1rem; border: 1px solid var(--line); font-size: .69rem; text-transform: uppercase; letter-spacing: .12em; }
.header-cta span { transition: transform .3s ease; }
.header-cta:hover span { transform: translate(3px,-3px); }
.menu-toggle { display: none; border: 0; background: transparent; width: 38px; height: 38px; padding: 0; z-index: 102; }
.menu-toggle span:not(.sr-only) { display: block; width: 24px; height: 1px; margin: 6px auto; background: currentColor; transition: transform .3s ease; }

.hero {
  position: relative;
  min-height: 100svh;
  padding: 112px 4vw 28px;
  display: grid;
  grid-template-columns: minmax(350px, .82fr) minmax(0, 1.45fr);
  gap: clamp(2rem, 5vw, 7rem);
  align-items: center;
}
.hero__copy { padding-left: clamp(0rem, 4vw, 4rem); position: relative; z-index: 2; }
.hero__title {
  margin: 1.7rem 0 2rem;
  font-family: var(--serif);
  font-size: clamp(3rem, 5.6vw, 6.6rem);
  font-weight: 400;
  line-height: .92;
  letter-spacing: -.045em;
}
.hero__text { max-width: 31rem; margin: 0 0 2.4rem; color: var(--muted); font-size: clamp(.95rem, 1.25vw, 1.13rem); }
.hero__authority { margin-top: 2rem; display: flex; flex-wrap: wrap; gap: 1rem; }
.hero__authority-item { display: inline-flex; flex-direction: column; gap: .3rem; min-width: 180px; padding: 1rem 1.1rem; border: 1px solid var(--line); background: rgba(255,255,255,.38); backdrop-filter: blur(8px); }
.hero__authority-item strong { font-family: var(--serif); font-size: clamp(2rem, 3vw, 2.8rem); font-weight: 400; line-height: .9; }
.hero__authority-item span { font-size: .72rem; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.text-link { display: inline-flex; align-items: center; gap: 1.3rem; padding-bottom: .55rem; border-bottom: 1px solid var(--ink); font-size: .72rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; }
.text-link span { transition: transform .3s ease; }
.text-link:hover span { transform: translateX(6px); }
.hero__visual { position: relative; height: calc(100svh - 140px); min-height: 560px; overflow: hidden; }
.hero__visual img { height: 112%; object-fit: cover; transform: translateY(-5%); }
.hero__shade { position: absolute; inset: 0; background: linear-gradient(to top, rgba(16,16,14,.38), transparent 36%); }
.hero__caption { position: absolute; left: 1.5rem; right: 1.5rem; bottom: 1.4rem; display: flex; justify-content: space-between; color: #fff; font-size: .65rem; letter-spacing: .12em; text-transform: uppercase; }
.hero__scroll { position: absolute; left: 1.5vw; bottom: 2rem; display: flex; align-items: center; gap: 1rem; writing-mode: vertical-rl; font-size: .58rem; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.hero__scroll i { width: 1px; height: 48px; background: var(--line); position: relative; overflow: hidden; }
.hero__scroll i::after { content: ""; position: absolute; inset: 0; background: var(--ink); transform: translateY(-100%); animation: scrollLine 2s infinite ease-in-out; }
@keyframes scrollLine { 50%,100% { transform: translateY(100%); } }

.manifesto { background: var(--paper); }
.manifesto__grid { display: grid; grid-template-columns: .55fr 1.45fr; gap: 8vw; align-items: start; }
.manifesto__meta { display: flex; min-height: 100%; flex-direction: column; }
.manifesto__aside {
  width: min(100%, 290px);
  margin-top: clamp(3.5rem, 7vw, 7.5rem);
  padding-top: 1.45rem;
  border-top: 1px solid var(--line);
}
.manifesto__mark {
  width: 58px;
  height: 58px;
  margin-bottom: 1.45rem;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  font-family: var(--serif);
  font-size: 2rem;
  line-height: 1;
}
.manifesto__aside-copy {
  margin: 0 0 2rem;
  color: var(--muted);
  font-size: .87rem;
  line-height: 1.7;
}
.manifesto__values { margin: 0; }
.manifesto__values div {
  display: grid;
  grid-template-columns: 34px 1fr;
  gap: .75rem;
  padding: .78rem 0;
  border-top: 1px solid var(--line);
}
.manifesto__values div:last-child { border-bottom: 1px solid var(--line); }
.manifesto__values dt,
.manifesto__values dd { margin: 0; }
.manifesto__values dt { color: var(--accent); font-size: .62rem; letter-spacing: .12em; }
.manifesto__values dd { font-size: .68rem; font-weight: 500; letter-spacing: .09em; text-transform: uppercase; }
.manifesto__content .display-title { max-width: 1100px; }
.manifesto__body { max-width: 760px; margin: 4rem 0 0 auto; display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; color: var(--muted); font-size: .96rem; }
.manifesto__body p { margin: 0; }

.feature-image { position: relative; width: 100%; height: min(78vw, 820px); overflow: hidden; }
.feature-image img { height: 115%; object-fit: cover; object-position: center 44%; }
.feature-image__note { position: absolute; right: 4vw; bottom: 4vw; padding: 1.4rem 1.6rem; background: rgba(249,248,244,.9); backdrop-filter: blur(12px); display: flex; flex-direction: column; font-family: var(--serif); font-size: clamp(1.2rem, 2.4vw, 2.2rem); line-height: 1.1; }

.services { background: var(--bg); }
.section-head { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; padding-bottom: 4rem; border-bottom: 1px solid var(--line); }
.section-head__intro { max-width: 460px; margin: auto 0 0 auto; color: var(--muted); }
.service-list { border-bottom: 1px solid var(--line); }
.service-item { display: grid; grid-template-columns: 70px 1fr minmax(260px, .7fr) 30px; gap: 2rem; align-items: center; padding: 2.1rem 0; border-top: 1px solid var(--line); transition: padding .3s ease, background .3s ease; }
.service-item:first-child { border-top: 0; }
.service-item > span { color: var(--muted); font-size: .7rem; }
.service-item h3 { margin: 0; font-family: var(--serif); font-size: clamp(1.6rem, 3vw, 3rem); font-weight: 400; }
.service-item p { margin: 0; color: var(--muted); font-size: .9rem; }
.service-item i { font-style: normal; font-size: 1.2rem; transition: transform .3s ease; }
.service-item:hover { padding-inline: 1rem; background: rgba(255,255,255,.32); }
.service-item:hover i { transform: translate(4px,-4px); }

.projects { background: var(--dark); color: #f2f0e9; }
.projects__top { display: grid; grid-template-columns: 1.6fr .65fr; gap: 5rem; align-items: end; }
.projects__top p:last-child { max-width: 420px; margin: 0 0 .7rem; color: #aaa99f; }
.projects .display-title { margin-top: 1.5rem; }
.project-filters { display: flex; gap: 1rem; margin: 4.5rem 0 2.5rem; border-bottom: 1px solid rgba(255,255,255,.17); }
.project-filters button { border: 0; background: transparent; color: #aaa99f; padding: 0 0 1rem; margin-right: 2rem; cursor: pointer; position: relative; text-transform: uppercase; letter-spacing: .12em; font-size: .67rem; }
.project-filters button::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 1px; background: #fff; transform: scaleX(0); transition: transform .3s ease; }
.project-filters button.is-active { color: #fff; }
.project-filters button.is-active::after { transform: scaleX(1); }
.project-filters sup { margin-left: .25rem; opacity: .55; }
.project-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 5rem 1.3rem; }
.project-card { cursor: pointer; transition: opacity .35s ease, transform .35s ease; }
.project-card.is-hidden { display: none; }
.project-card--extra { display: none; }
.project-grid.is-expanded .project-card--extra { display: block; }
.project-card__image { aspect-ratio: 4 / 3; overflow: hidden; background: #333; }
.project-card__image img { height: 100%; object-fit: cover; transition: transform .9s cubic-bezier(.2,.7,.2,1), filter .5s ease; }
.project-card:hover .project-card__image img { transform: scale(1.035); filter: brightness(.83); }
.project-card__meta { display: flex; align-items: flex-start; justify-content: space-between; padding-top: 1rem; border-top: 1px solid rgba(255,255,255,.14); margin-top: .8rem; }
.project-card__meta h3 { margin: 0 0 .2rem; font-family: var(--serif); font-size: clamp(1.35rem, 2vw, 2rem); font-weight: 400; }
.project-card__meta p, .project-card__meta span { margin: 0; color: #8e8d86; font-size: .62rem; letter-spacing: .12em; text-transform: uppercase; }
.load-more { margin: 5rem auto 0; display: flex; align-items: center; gap: 2rem; border: 1px solid rgba(255,255,255,.26); padding: 1rem 1.3rem; background: transparent; color: #fff; cursor: pointer; text-transform: uppercase; font-size: .68rem; letter-spacing: .13em; }
.load-more i { font-style: normal; font-size: 1rem; transition: transform .35s ease; }
.load-more:hover i { transform: rotate(90deg); }

.quote-section { display: grid; grid-template-columns: 1.25fr .75fr; min-height: 760px; background: #d9d0c2; }
.quote-section__image { overflow: hidden; }
.quote-section__image img { height: 115%; object-fit: cover; }
.quote-section__copy { padding: clamp(3rem, 7vw, 8rem); display: flex; flex-direction: column; justify-content: center; }
.quote-section blockquote { margin: 3rem 0; font-family: var(--serif); font-size: clamp(2.3rem, 4.8vw, 5.2rem); line-height: 1.04; letter-spacing: -.035em; }
.quote-section__copy > span { color: var(--muted); font-size: .78rem; }

.process { background: var(--paper); }
.process__layout { display: grid; grid-template-columns: .8fr 1.2fr; gap: 9vw; }
.process__intro { position: sticky; top: 120px; align-self: start; }
.process__intro .display-title { margin: 1.3rem 0 2rem; }
.process__intro > p:last-child { max-width: 440px; color: var(--muted); }
.process__steps { margin: 0; padding: 0; list-style: none; }
.process__steps li { display: grid; grid-template-columns: 70px 1fr; gap: 1.5rem; padding: 2.5rem 0; border-top: 1px solid var(--line); }
.process__steps li:last-child { border-bottom: 1px solid var(--line); }
.process__steps span { color: var(--muted); font-size: .7rem; }
.process__steps h3 { margin: 0 0 .7rem; font-family: var(--serif); font-size: clamp(1.7rem, 3vw, 2.8rem); font-weight: 400; }
.process__steps p { margin: 0; max-width: 500px; color: var(--muted); }

.contact { position: relative; min-height: 78vh; display: grid; place-items: center; overflow: hidden; background: #b8aa97; }
.contact__background { position: absolute; inset: -10%; background: radial-gradient(circle at 30% 40%, rgba(255,255,255,.58), transparent 36%), radial-gradient(circle at 78% 62%, rgba(75,59,41,.2), transparent 34%); filter: blur(14px); }
.contact__inner { position: relative; z-index: 1; text-align: center; max-width: 1000px; padding: 6rem 0; }
.contact h2 { margin: 1.6rem 0 2rem; font-family: var(--serif); font-size: clamp(3.2rem, 8vw, 8.8rem); font-weight: 400; line-height: .88; letter-spacing: -.05em; }
.contact__inner > p:not(.eyebrow) { max-width: 540px; margin: 0 auto 2.5rem; }
.contact__button { display: inline-flex; align-items: center; gap: 2.5rem; padding: 1.1rem 1.3rem; background: var(--dark); color: #fff; font-size: .68rem; text-transform: uppercase; letter-spacing: .13em; }
.contact__button i { font-style: normal; transition: transform .3s ease; }
.contact__button:hover i { transform: translate(4px,-4px); }

.footer { padding: 5rem 0 1.5rem; background: #181a17; color: #efede6; }
.footer__grid { display: grid; grid-template-columns: 1.2fr .6fr .6fr 1fr; gap: 4rem; }
.footer__brand { display: flex; flex-direction: column; align-items: flex-start; }
.footer__brand .brand__name { font-size: 2.4rem; }
.footer__label { margin: 0 0 1.1rem; color: #797a73; font-size: .62rem; text-transform: uppercase; letter-spacing: .14em; }
.footer__grid > div:not(:first-child) a { display: block; margin: .45rem 0; color: #b5b5ae; font-size: .85rem; }
.footer__statement { font-family: var(--serif); font-size: clamp(1.6rem, 3vw, 2.7rem); line-height: 1.05; }
.footer__bottom { margin-top: 5rem; padding-top: 1.4rem; border-top: 1px solid rgba(255,255,255,.12); display: flex; justify-content: space-between; color: #6f706b; font-size: .62rem; text-transform: uppercase; letter-spacing: .1em; }

.project-modal { position: fixed; inset: 0; z-index: 300; display: grid; grid-template-columns: 1fr; background: var(--paper); opacity: 0; visibility: hidden; transform: translateY(18px); transition: opacity .4s ease, visibility .4s ease, transform .4s ease; }
.project-modal.is-open { opacity: 1; visibility: visible; transform: none; }
.project-modal__media { min-height: 100vh; overflow: hidden; background: #ddd; }
.project-modal__media { display: flex; align-items: center; justify-content: center; background: var(--paper); }
.project-modal__media img { width: 100%; height: 100%; object-fit: contain; }
.project-modal__content { padding: clamp(5rem, 9vw, 9rem) clamp(2rem, 5vw, 5rem); display: flex; flex-direction: column; justify-content: center; }
.project-modal__content h2 { margin: 1.5rem 0 2rem; font-family: var(--serif); font-size: clamp(2.8rem, 5vw, 5.8rem); font-weight: 400; line-height: .95; }
.project-modal__content > p:not(.eyebrow) { color: var(--muted); max-width: 460px; }
.project-modal__detail { margin-top: 4rem; padding-top: 1.2rem; border-top: 1px solid var(--line); display: flex; justify-content: space-between; color: var(--muted); font-size: .67rem; text-transform: uppercase; letter-spacing: .11em; }
.project-modal__close { position: absolute; top: 1.5rem; right: 1.5rem; z-index: 2; width: 48px; height: 48px; border: 1px solid var(--line); background: rgba(255,255,255,.7); cursor: pointer; font-size: 1.7rem; line-height: 1; }

.floating-contact { position: fixed; right: 1.4rem; bottom: 1.4rem; z-index: 80; width: 82px; height: 82px; border-radius: 50%; background: var(--dark); color: #fff; display: flex; align-items: center; justify-content: center; gap: .25rem; font-size: .55rem; line-height: 1.2; letter-spacing: .1em; text-transform: uppercase; box-shadow: 0 10px 35px rgba(0,0,0,.18); transition: transform .3s ease; }
.floating-contact i { font-style: normal; }
.floating-contact:hover { transform: rotate(-6deg) scale(1.05); }

.reveal { opacity: 0; transform: translateY(28px); transition: opacity .8s ease, transform .8s cubic-bezier(.2,.75,.2,1); }
.reveal.is-visible { opacity: 1; transform: none; }
.reveal-image { clip-path: inset(0 0 100% 0); transition: clip-path 1.2s cubic-bezier(.2,.8,.2,1); }
.reveal-image.is-visible { clip-path: inset(0); }

.cursor { display: none; }

@media (min-width: 1025px) and (pointer: fine) {
  body, a, button, .project-card { cursor: none; }
  .cursor { position: fixed; left: 0; top: 0; z-index: 10000; width: 64px; height: 64px; border-radius: 50%; background: rgba(242,240,233,.9); color: #1c1d1a; display: grid; place-items: center; pointer-events: none; transform: translate(-50%,-50%) scale(.32); mix-blend-mode: difference; transition: transform .25s ease, background .25s ease; }
  .cursor span { opacity: 0; font-size: .56rem; text-transform: uppercase; letter-spacing: .12em; }
  .cursor.is-active { transform: translate(-50%,-50%) scale(1); mix-blend-mode: normal; }
  .cursor.is-active span { opacity: 1; }
}

@media (max-width: 1024px) {
  .site-header { height: 72px; }
  .main-nav { position: fixed; inset: 0; z-index: 101; background: var(--paper); flex-direction: column; align-items: center; justify-content: center; gap: 1.6rem; font-family: var(--serif); font-size: clamp(2.4rem, 9vw, 5rem); text-transform: none; letter-spacing: -.03em; opacity: 0; visibility: hidden; transition: opacity .35s ease, visibility .35s ease; }
  .main-nav.is-open { opacity: 1; visibility: visible; }
  .header-cta { display: none; }
  .menu-toggle { display: block; }
  .menu-toggle.is-open span:first-child { transform: translateY(3.5px) rotate(45deg); }
  .menu-toggle.is-open span:nth-child(2) { transform: translateY(-3.5px) rotate(-45deg); }
  .hero { grid-template-columns: 1fr; padding: 110px 4vw 1.5rem; gap: 3rem; }
  .hero__copy { padding: 0; }
  .hero__visual { height: 68svh; min-height: 520px; }
  .hero__scroll { display: none; }
  .manifesto__grid { grid-template-columns: 1fr; gap: 3rem; }
  .manifesto__aside { display: none; }
  .manifesto__body { margin-left: 0; }
  .service-item { grid-template-columns: 55px 1fr 30px; }
  .service-item p { grid-column: 2 / 3; }
  .projects__top { grid-template-columns: 1fr; gap: 2rem; }
  .quote-section { grid-template-columns: 1fr; }
  .quote-section__image { min-height: 65vh; }
  .process__layout { grid-template-columns: 1fr; gap: 4rem; }
  .process__intro { position: static; }
  .footer__grid { grid-template-columns: 1fr 1fr; }
  .project-modal { grid-template-columns: 1fr; overflow-y: auto; }
  .project-modal__media { min-height: 56vh; height: 56vh; }
  .project-modal__content { min-height: 44vh; }
}

@media (max-width: 720px) {
  .hero__authority { margin-top: 1.6rem; }
  .hero__authority-item { min-width: 0; width: 100%; }
  :root { --container: 90vw; }
  .section-pad { padding: 5.5rem 0; }
  .site-header { padding-inline: 5vw; }
  .hero { padding-inline: 5vw; }
  .hero__title { font-size: clamp(3rem, 15vw, 5rem); }
  .hero__text { max-width: 90%; }
  .hero__visual { min-height: 430px; height: 58svh; }
  .hero__caption { left: 1rem; right: 1rem; }
  .manifesto__body { grid-template-columns: 1fr; gap: 1.4rem; margin-top: 2.6rem; }
  .feature-image { height: 112vw; }
  .feature-image__note { left: 5vw; right: auto; bottom: 5vw; }
  .section-head { grid-template-columns: 1fr; gap: 2rem; }
  .section-head__intro { margin: 0; }
  .service-item { grid-template-columns: 36px 1fr 20px; gap: 1rem; padding: 1.6rem 0; }
  .service-item p { font-size: .82rem; }
  .project-filters { overflow-x: auto; gap: 0; margin-top: 3rem; scrollbar-width: none; }
  .project-filters::-webkit-scrollbar { display: none; }
  .project-filters button { flex: 0 0 auto; margin-right: 1.7rem; }
  .project-grid { grid-template-columns: 1fr; gap: 3.5rem; }
  .project-card:nth-child(even) { margin-left: 8vw; }
  .project-card:nth-child(odd) { margin-right: 8vw; }
  .quote-section { min-height: auto; }
  .quote-section__image { min-height: 60vh; }
  .quote-section__copy { padding: 4.5rem 5vw 5rem; }
  .process__steps li { grid-template-columns: 40px 1fr; }
  .contact { min-height: 78svh; }
  .contact h2 { font-size: clamp(3.2rem, 16vw, 5.8rem); }
  .footer__grid { grid-template-columns: 1fr 1fr; gap: 3rem 1.5rem; }
  .footer__brand, .footer__statement { grid-column: 1 / -1; }
  .footer__bottom { flex-direction: column; gap: .8rem; }
  .floating-contact { width: 68px; height: 68px; right: 1rem; bottom: 1rem; }
  .project-modal__media { min-height: 48vh; height: 48vh; }
  .project-modal__content { padding: 3.5rem 6vw; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  .reveal { opacity: 1; transform: none; }
  .reveal-image { clip-path: none; }
}


.project-modal__media { display: grid; grid-template-columns: 1fr; gap: 1rem; padding: 1rem; overflow-y: auto; align-content: start; }
.project-modal__media.has-gallery { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.project-modal__media img { width: 100%; height: auto; max-height: calc(100vh - 2rem); object-fit: cover; }
.project-modal__media img[hidden] { display: none !important; }
@media (max-width: 900px) {
  .project-modal__media.has-gallery { grid-template-columns: 1fr; }
  .project-modal__media img { max-height: none; }
}



/* Final image gallery adjustments */
.hero__title {
  font-size: clamp(3rem, 5.2vw, 6.2rem);
}
.project-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 2.2rem 1.2rem;
}
.project-card__image {
  aspect-ratio: auto;
  background: transparent;
}
.project-card__image img {
  width: 100%;
  height: auto;
  object-fit: contain;
}
.project-card:hover .project-card__image img {
  transform: none;
  filter: none;
}
.project-card__meta {
  padding-top: .75rem;
  margin-top: .75rem;
  min-height: 1.5rem;
}
.project-card__meta h3,
.project-modal h2,
.project-modal [data-modal-description] {
  display: none;
}
.project-card__meta {
  justify-content: flex-end;
}
.project-card__meta p {
  margin-right: auto;
}
@media (max-width: 980px) {
  .project-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .project-grid { grid-template-columns: 1fr; }
  .hero__title { font-size: clamp(2.4rem, 10.4vw, 3.8rem); }
}


/* Portfolio authority and image viewer refinements */
.projects__authority {
  align-self: end;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 1rem;
  align-items: end;
  padding-top: 1rem;
  border-top: 1px solid rgba(255,255,255,.18);
  color: #aaa99f;
}
.projects__authority-number {
  font-family: var(--serif);
  font-size: clamp(2.7rem, 4.4vw, 4.8rem);
  font-weight: 400;
  line-height: .82;
  color: #fff;
}
.projects__authority-copy {
  display: flex;
  flex-direction: column;
  gap: .35rem;
}
.projects__authority-copy span {
  color: #fff;
  font-size: .68rem;
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
}
.projects__authority-copy p {
  max-width: 310px !important;
  margin: 0 !important;
  color: #aaa99f !important;
  font-size: .88rem;
  line-height: 1.5;
}

.project-modal__media,
.project-modal__media.has-gallery {
  min-height: 100vh !important;
  height: 100vh !important;
  padding: clamp(1rem, 2vw, 2rem) !important;
  overflow: auto !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  background: #171815 !important;
}
.project-modal__media img {
  display: block !important;
  width: auto !important;
  height: auto !important;
  max-width: 100% !important;
  max-height: calc(100vh - clamp(2rem, 4vw, 4rem)) !important;
  object-fit: contain !important;
  object-position: center !important;
  transform: none !important;
}
.project-modal__media img[hidden] {
  display: none !important;
}

@media (max-width: 900px) {
  .projects__authority {
    max-width: 520px;
  }
  .project-modal__media,
  .project-modal__media.has-gallery {
    min-height: 58svh !important;
    height: 58svh !important;
    padding: .8rem !important;
  }
  .project-modal__media img {
    max-width: 100% !important;
    max-height: calc(58svh - 1.6rem) !important;
  }
}

@media (max-width: 720px) {
  .projects__authority {
    grid-template-columns: auto 1fr;
    gap: .8rem;
    margin-top: 1rem;
  }
  .projects__authority-number {
    font-size: 3rem;
  }
  .projects__authority-copy p {
    font-size: .82rem;
  }
}


/* Prevent iOS/Safari from rendering the diagonal arrow as an emoji */
.arrow-glyph {
  display: block;
  width: 1em;
  height: 1em;
  overflow: visible;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.45;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.service-item i,
.contact .button i,
.floating-contact i,
.header-cta span {
  display: inline-grid;
  place-items: center;
}


/* Portfolio without numbering + mobile carousel */
.project-card__meta span { display: none !important; }
.project-card__meta { justify-content: flex-start; }
.project-card__meta p { margin-right: 0; }
.project-carousel-controls { display: none; }

@media (max-width: 720px) {
  .projects .container { overflow: visible; }
  .project-grid {
    display: flex !important;
    grid-template-columns: none !important;
    gap: 1rem !important;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-snap-type: x mandatory;
    scroll-padding-inline: 5vw;
    overscroll-behavior-x: contain;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    margin-right: -5vw;
    padding: 0 5vw 1rem 0;
  }
  .project-grid::-webkit-scrollbar { display: none; }
  .project-card {
    flex: 0 0 min(82vw, 430px);
    max-width: min(82vw, 430px);
    scroll-snap-align: center;
    scroll-snap-stop: always;
  }
  .project-card__image {
    width: 100%;
    height: min(66svh, 580px);
    min-height: 430px;
    display: grid;
    place-items: center;
    background: #171815;
    overflow: hidden;
  }
  .project-card__image img {
    width: 100% !important;
    height: 100% !important;
    object-fit: contain !important;
    object-position: center !important;
  }
  .project-carousel-controls {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-top: 1.15rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(255,255,255,.16);
  }
  .project-carousel-controls p {
    margin: 0;
    color: #8e8d86;
    font-size: .62rem;
    font-weight: 600;
    letter-spacing: .14em;
    text-transform: uppercase;
  }
  .project-carousel-button {
    width: 44px;
    height: 44px;
    border: 1px solid rgba(255,255,255,.28);
    border-radius: 50%;
    display: grid;
    place-items: center;
    background: transparent;
    color: #fff;
    cursor: pointer;
  }
  .project-carousel-button span {
    width: 9px;
    height: 9px;
    border-top: 1.5px solid currentColor;
    border-right: 1.5px solid currentColor;
  }
  .project-carousel-button--next span { transform: rotate(45deg); margin-left: -3px; }
  .project-carousel-button--prev span { transform: rotate(-135deg); margin-right: -3px; }
}
@media (max-width: 720px) {
  .preloader__logo { width: min(72vw, 300px); }
  .brand__logo { width: 132px; }
}


/* Portfólio único em carrossel — desktop e mobile */
.project-filters { display: none !important; }
.projects .container { overflow: visible; }
.project-grid {
  display: flex !important;
  grid-template-columns: none !important;
  gap: clamp(1rem, 1.6vw, 1.5rem) !important;
  overflow-x: auto !important;
  overflow-y: hidden !important;
  scroll-snap-type: x mandatory;
  scroll-padding-inline: max(4vw, calc((100vw - var(--container)) / 2));
  overscroll-behavior-x: contain;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  padding: 0 0 1rem;
}
.project-grid::-webkit-scrollbar { display: none; }
.project-card {
  flex: 0 0 clamp(300px, 31vw, 470px) !important;
  max-width: clamp(300px, 31vw, 470px) !important;
  scroll-snap-align: start;
  scroll-snap-stop: always;
}
.project-card__image {
  width: 100% !important;
  aspect-ratio: 4 / 3 !important;
  height: auto !important;
  min-height: 0 !important;
  display: block !important;
  overflow: hidden !important;
  background: transparent !important;
  border: 0 !important;
}
.project-card__image img {
  display: block !important;
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  object-position: center !important;
  background: transparent !important;
  border: 0 !important;
  transform: none !important;
}
.project-card:hover .project-card__image img {
  transform: scale(1.018) !important;
  filter: brightness(.92) !important;
}
.project-carousel-controls {
  display: flex !important;
  align-items: center;
  justify-content: flex-end;
  gap: 1rem;
  margin-top: 1.4rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(255,255,255,.16);
}
.project-carousel-controls p {
  margin: 0 auto 0 0;
  color: #8e8d86;
  font-size: .62rem;
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
}
.project-carousel-button {
  width: 44px;
  height: 44px;
  flex: 0 0 44px;
  border: 1px solid rgba(255,255,255,.28);
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: transparent;
  color: #fff;
  cursor: pointer;
}
.project-carousel-button span {
  width: 9px;
  height: 9px;
  border-top: 1px solid currentColor;
  border-right: 1px solid currentColor;
}
.project-carousel-button--next span { transform: rotate(45deg); margin-left: -3px; }
.project-carousel-button--prev span { transform: rotate(-135deg); margin-right: -3px; }

/* Menu móvel estável mesmo após rolagem */
@media (max-width: 1024px) {
  .site-header.menu-open,
  .site-header.is-scrolled.menu-open {
    height: 84px !important;
    background: var(--paper) !important;
    border-color: transparent !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
  }
  .main-nav {
    position: fixed !important;
    inset: 0 !important;
    width: 100vw !important;
    height: 100dvh !important;
    min-height: 100svh !important;
    padding: 110px 5vw 40px !important;
    overflow-y: auto !important;
    box-sizing: border-box;
  }
  .site-header.menu-open .brand,
  .site-header.menu-open .menu-toggle {
    position: relative;
    z-index: 103;
  }
}

@media (max-width: 720px) {
  .project-grid {
    gap: 1rem !important;
    margin-right: -5vw !important;
    padding-right: 5vw !important;
    scroll-padding-inline: 0;
  }
  .project-card {
    flex-basis: min(84vw, 420px) !important;
    max-width: min(84vw, 420px) !important;
    scroll-snap-align: center;
  }
  .project-card__image {
    aspect-ratio: 4 / 3 !important;
  }
  .project-carousel-controls {
    margin-top: 1.1rem;
  }
}



/* Espaçamento entre a apresentação do portfólio e o carrossel */
.projects__top {
  margin-bottom: clamp(3rem, 5vw, 5rem) !important;
}
@media (max-width: 720px) {
  .projects__top {
    margin-bottom: 2.75rem !important;
  }
}

