It is necessary to make it so that when you hover the lower unit flies to the left of the upper block, and at the same time, the upper block flies to the right beyond the block borders. How to do this?
section { margin: 20px auto; padding: 20px; width: 240px; background-color: white; border: 1px solid #cccccc; } .title { height: 240px; width: 240px; text-align: center; box-sizing: border-box; font-size: 20px; font-weight: bold; color: #fff; background-color: #cccccc; padding-top: 100px; } .description { height: 240px; width: 240px; text-align: center; box-sizing: border-box; font-size: 16px; font-weight: bold; color: #fff; background-color: #333333; padding-top: 80px; } <section class="works"> <a class="caption-link"> <div class="title">Продаем телефоны</div> <div class="description">Телефоны всех марок за доступной ценой и для любого метода оплаты.</div> </a> </section>