/* Anastasia Rybas — portfolio. Design canvas is 1920px wide; 1rem = 10px at 1920. */

@font-face {
  font-family: 'Punta TEST';
  src: url('/fonts/PuntaTEST-Medium.woff2') format('woff2');
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Proxima Nova';
  src: url('/fonts/ProximaNova-Medium.woff2') format('woff2');
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

:root {
  --grey: #a0a0a0;
  --line: #e1e1e1;
  --cream: #fffbe8;
  --serif: 'Punta TEST', 'EB Garamond', Georgia, 'Times New Roman', serif;
  --sans: 'Proxima Nova', 'Helvetica Neue', Helvetica, Arial, sans-serif;
  --pill: linear-gradient(to top, var(--cream) 0%, #fff 100%);
  --panel: rgba(237, 237, 237, 0.31);
  --radius: 0.9rem;
}

html { font-size: calc(100vw / 192); -webkit-text-size-adjust: 100%; }
* { box-sizing: border-box; }
body {
  margin: 0;
  background: #fff;
  color: #000;
  font-family: var(--sans);
  font-weight: 500;
  font-size: 2.4rem;
  line-height: 1;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
p { margin: 0; }
.g { color: var(--grey); }

.page { position: relative; padding: 3rem 3rem 3rem; }

/* ---------- Header ---------- */
.header {
  position: absolute;
  top: 3rem; left: 3rem; right: 3rem;
  z-index: 5;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}
.logo {
  font-family: var(--serif);
  font-size: 3rem;
  line-height: 0.93;
  letter-spacing: -0.03rem;
  text-transform: uppercase;
  white-space: nowrap;
}
.nav {
  position: absolute;
  left: 50%;
  top: 0.2rem;
  transform: translateX(-50%);
  display: flex;
  gap: 5.3rem;
  white-space: nowrap;
}
.nav a { color: var(--grey); transition: color .2s; }
.nav a:hover, .nav a.is-active { color: #000; }
.cta { display: flex; align-items: flex-start; gap: 0.6rem; white-space: nowrap; margin-top: -0.1rem; }
.cta .arrow { font-family: var(--serif); font-size: 2.8rem; line-height: 0.93; letter-spacing: -0.028rem; }
.cta span:last-child { margin-top: 0.5rem; }
.cta:hover { opacity: .6; }

/* ---------- Hero pill ---------- */
.hero {
  height: 53.2rem;
  border-radius: 29.8rem;
  background: var(--pill);
  display: flex;
  align-items: center;
  justify-content: center;
}
.hero--tall { height: 100rem; }
.hero h1 {
  margin: 0;
  font-family: var(--serif);
  font-weight: 500;
  font-size: 7.49rem;
  line-height: 0.93;
  letter-spacing: -0.075rem;
  text-transform: uppercase;
  text-align: center;
}

.arrow { font-family: var(--serif); }

/* ---------- Containers ---------- */
.container { width: 154.6rem; margin: 0 auto; }

/* ---------- Home: featured projects ---------- */
.feature-list { margin-top: 6rem; display: flex; flex-direction: column; gap: 12rem; }
.feature { display: grid; grid-template-columns: 47rem 107.6rem; }
.feature__caption { max-width: 42.1rem; line-height: 1; }
.feature__img { aspect-ratio: 1076/845; border-radius: var(--radius); overflow: hidden; }
.feature__img img { width: 100%; height: 100%; object-fit: cover; }
.feature-list + .more { margin-top: 6rem; }

/* ---------- Projects grid ---------- */
.grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6rem 2.2rem; margin-top: 3rem; }
.card { display: block; }
.card__img { aspect-ratio: 605/755; border-radius: var(--radius); overflow: hidden; }
.card__img img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s ease; }
a.card:hover .card__img img { transform: scale(1.02); }
.card p { margin-top: 1.5rem; max-width: 48rem; line-height: 1; }
.grid3 + .more { margin-top: 15rem; }

/* ---------- "→ More" link + footer ---------- */
.more {
  width: 154.6rem;
  margin: 0 auto 6rem;
  border-top: 1px solid var(--line);
  padding-top: 6rem;
}
.more a { display: inline-flex; align-items: baseline; }
.more .arrow { font-family: var(--serif); font-size: 5.9rem; line-height: 0.93; letter-spacing: -0.059rem; white-space: pre; }
.more .txt { font-size: 4.72rem; line-height: 1; }
.more a:hover { opacity: .6; }

.footer {
  position: relative;
  height: 12.5rem;
  border-radius: 1.3rem;
  background: var(--panel);
  color: var(--grey);
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  column-gap: 2.2rem;
  align-items: center;
}
.footer__col:first-child { padding-left: 4.5rem; }
.footer__links { display: flex; gap: 5rem; }
.footer a:hover { color: #000; }
.footer__year { position: absolute; right: 5.8rem; top: 50%; transform: translateY(-50%); }

/* ---------- About ---------- */
.about { width: 154.6rem; margin: 12.9rem auto 0; display: flex; align-items: flex-start; }
.about__photo { width: 41.7rem; height: 38.38rem; border-radius: 13.68rem; overflow: hidden; flex: none; }
.about__photo img { width: 100%; height: 100%; object-fit: cover; }
.about__text { margin-left: 36.5rem; margin-top: 4.4rem; width: 55.7rem; line-height: 1; }
.about__text p + p { margin-top: 2.4rem; }

.partners {
  width: 154.6rem;
  height: 12.5rem;
  margin: 17.5rem auto 0;
  border-radius: 1.3rem;
  background: var(--panel);
  display: flex;
  align-items: center;
  padding-left: 5rem;
  color: var(--grey);
}
.partners__label { width: 23.1rem; flex: none; }
.plogo { display: contents; }
.partners img {
  flex: none;
  width: calc(var(--w) * 0.1rem);
  height: calc(var(--h) * 0.1rem);
  margin-left: calc(var(--ml) * 0.1rem);
}
.partners .divider { width: 1px; height: 6.46rem; margin-left: 3.3rem; background: #e6e6e6; flex: none; }

.contact-pills { width: 100%; margin-top: 6rem; display: flex; gap: 2.1rem; }
.contact-pill {
  flex: 1;
  height: 51rem;
  border-radius: 19rem;
  background: linear-gradient(to top, var(--cream) 0%, #fff 77.3%);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #000;
}
.contact-pill .arrow { font-size: 5.9rem; line-height: 0.93; letter-spacing: -0.059rem; white-space: pre; }
.contact-pill .txt { font-size: 4.72rem; line-height: 1; }
.contact-pill:hover { opacity: .75; }
.contact-pills + .footer { margin-top: 3.1rem; }

/* ---------- Archive tiles ---------- */
.tiles { display: grid; grid-template-columns: repeat(5, 1fr); gap: 10rem 2.25rem; margin-top: 3rem; }
.tile {
  position: relative;
  aspect-ratio: 1;
  border-radius: var(--radius);
  overflow: hidden;
  background: #fff;
  container-type: inline-size;
}
.tile > * { position: absolute; }
.tile .cover { inset: 0; width: 100%; height: 100%; object-fit: cover; }
.tile .box { overflow: hidden; }
.tile .box > img { position: absolute; }
.tiles + .more { margin-top: 9rem; }

/* Generic positioned element: --x/--y/--w/--h in design px, --b = box width in px */
.el {
  position: absolute;
  --b: 354;
  left: calc(var(--x) * 100cqw / var(--b));
  top: calc(var(--y) * 100cqw / var(--b));
  width: calc(var(--w) * 100cqw / var(--b));
  height: calc(var(--h) * 100cqw / var(--b));
  max-width: none;
}
.tile .el, .tile3 .el { position: absolute; }
.tile .pill { background: #171717; border-radius: 999px; }
.tile .dark-text {
  color: #fff;
  font-family: var(--sans);
  font-size: calc(21.2 * 100cqw / 354);
  line-height: 0.9;
  letter-spacing: -0.02em;
  white-space: nowrap;
  z-index: 2;
}
.tile .line { background: #fff; transform-origin: center; }
.tile .masked { -webkit-mask-repeat: no-repeat; mask-repeat: no-repeat; -webkit-mask-size: 100% 100%; mask-size: 100% 100%; }
.tile .masked img { position: absolute; width: 100%; height: 100%; object-fit: cover; }

/* ---------- Case pages ---------- */
.ptitle {
  margin: 16rem 0 0;
  font-family: var(--serif);
  font-weight: 500;
  font-size: 7.49rem;
  line-height: 0.93;
  letter-spacing: -0.075rem;
  text-transform: uppercase;
}
.phero { margin-top: 3rem; width: 100%; border-radius: var(--radius); overflow: hidden; position: relative; }
.phero img { width: 100%; height: 100%; object-fit: cover; position: absolute; inset: 0; }

.content { width: 154.6rem; margin: 0 auto; display: flex; flex-direction: column; gap: 2.2rem; }
.content + .more { margin-top: 0; }

.tb { display: flex; gap: 14.6rem; padding: 10rem 0; }
.tb__label { width: 32.4rem; flex: none; color: var(--grey); line-height: 1; }
.tb__body { width: 70.5rem; line-height: 1.1; }
.tb__body p + p { margin-top: 1.1em; }

.img-full { position: relative; width: 100%; border-radius: var(--radius); overflow: hidden; }
.img-full.no-radius { border-radius: 0; }
.img-full img, .img-box img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.img-full.contain img { object-fit: contain; }

.pair { display: flex; gap: 2.2rem; }
.img-box { position: relative; flex: 1; border-radius: var(--radius); overflow: hidden; }
.img-box.contain img { object-fit: contain; }

.triple { display: flex; gap: 1.61rem; }
.tile3 {
  position: relative;
  flex: 1;
  border-radius: var(--radius);
  overflow: hidden;
  container-type: inline-size;
}
.tile3 .cover { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.tile3 .centered { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); }

.strip { position: relative; width: 100%; overflow: hidden; container-type: inline-size; }
.strip .el { position: absolute; }

.meta { display: flex; gap: 60.9rem; padding: 10rem 0; }
.meta__col { --w: 33.2; width: calc(var(--w) * 1rem); line-height: 1; }
.meta__col p { line-height: 1; }

/* ---------- Mobile ---------- */
@media (max-width: 820px) {
  html { font-size: calc(100vw / 75); }
  body { font-size: 3.2rem; }
  .page { padding: 2.4rem 2.4rem 2.4rem; }
  .header { position: static; flex-wrap: wrap; gap: 2rem 3rem; margin-bottom: 3rem; }
  .logo { font-size: 3.6rem; }
  .nav { position: static; transform: none; order: 3; width: 100%; gap: 4rem; }
  .cta .arrow { font-size: 3.6rem; }
  .cta span:last-child { margin-top: 0.4rem; }
  .hero { height: 64rem; border-radius: 30rem; padding: 0 4rem; }
  .hero--tall { height: 96rem; }
  .hero h1 { font-size: 7.4rem; }
  .container, .content, .more, .about, .partners, .contact-pills { width: 100%; }
  .feature { grid-template-columns: 1fr; gap: 2.4rem; }
  .feature__caption { max-width: 100%; }
  .feature-list { gap: 8rem; }
  .grid3 { grid-template-columns: 1fr; gap: 6rem; }
  .card p { max-width: 100%; }
  .more { padding-top: 4rem; margin-bottom: 4rem; }
  .more .arrow { font-size: 5rem; }
  .more .txt { font-size: 4.2rem; }
  .footer {
    height: auto;
    padding: 4.5rem 3rem 4.5rem;
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    column-gap: 3rem;
    row-gap: 3.4rem;
  }
  .footer__col:first-child { padding-left: 0; flex-basis: 100%; }
  /* Flatten both link groups into one row so all four links get equal spacing. */
  .footer { justify-content: space-between; }
  .footer__links { display: contents; }
  .footer__year { position: static; transform: none; flex-basis: 100%; margin-top: 1.4rem; }
  .about { flex-direction: column; margin-top: 6rem; }
  .about__photo { width: 60%; height: auto; aspect-ratio: 417/384; border-radius: 30%; }
  .about__text { margin: 4rem 0 0; width: 100%; }
  .partners {
    height: auto;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    align-items: center;
    justify-items: start;
    gap: 3.6rem 1.6rem;
    padding: 4rem 3rem;
    margin-top: 8rem;
  }
  .partners__label { grid-column: 1 / -1; width: auto; }
  .plogo { display: flex; align-items: center; gap: 1.2rem; }
  .partners img {
    width: calc(var(--w) * 0.13rem);
    height: auto;
    margin-left: 0;
  }
  .partners .divider {
    grid-column: 1 / -1;
    width: 100%;
    height: 1px;
    margin: 0.4rem 0;
  }
  .contact-pills { flex-direction: column; gap: 2.4rem; margin-top: 5rem; }
  .contact-pill { flex: none; height: 26rem; border-radius: 13rem; }
  .contact-pill .arrow { font-size: 5rem; }
  .contact-pill .txt { font-size: 4.2rem; }
  .tiles { grid-template-columns: repeat(2, 1fr); gap: 4rem 2.4rem; }
  .ptitle { margin-top: 2rem; font-size: 7rem; }
  .content { gap: 1.6rem; }
  .tb { flex-direction: column; gap: 2.4rem; padding: 6rem 0; }
  .tb__label, .tb__body { width: 100%; }
  .pair, .triple { flex-direction: column; gap: 1.6rem; }
  .meta { flex-direction: column; gap: 4rem; padding: 6rem 0; }
  .meta__col { width: 100% !important; }
}
