.cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  width: 100%;
  max-width: 1200px; 
  justify-content: center;
  justify-items: center; 
  gap: 30px; 
  margin: 0 auto;
  padding: 50px 20px;
}

.card {
  width: 100%;
  max-width: 320px;
  min-height: 420px;
  box-shadow: 1px 2px 4px rgba(0, 0, 0, 0.1);
  display: flex;
  flex-direction: column; 
  border-radius: 8px;
  transition: 0.2s;
  position: relative;
  background: white;
}

.card:hover {
  box-shadow: 4px 8px 16px rgba(64, 131, 94, 0.2);
  transform: translateY(-5px);
}

.top {
  flex: 0 0 250px; 
  position: relative;
  overflow: hidden; 
  border-radius: 8px 8px 0 0;
}

.image {
  display: block;
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

.image > img {
  width: 100%;
  height: 100%;
  object-fit: cover; 
  transition: 0.3s;
}

.image:hover > img {
  transform: scale(1.1);
}

.bottom {
    display: flex;
    flex-direction: column;
    flex: 1 0 auto; 
    padding: 15px;
}

.prices {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    width: 100%;
}

.flow {
    font-weight: 500;
    font-size: 16px;
    color: #677964;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.price {
    font-weight: 700;
    font-size: 18px;
    color: #414141;
    background: #f5f5f5;
    padding: 5px 10px;
    border-radius: 20px;
    white-space: nowrap;
}

.title {
    display: block;
    margin-bottom: 15px;
    font-weight: 400;
    font-size: 16px;
    line-height: 1.4;
    color: #414141;
    flex-grow: 1;
}





/* Адаптивность карточек */
@media (max-width: 768px) {
  .cards {
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
    padding: 30px 15px;
  }
  
  .card {
    max-width: 280px;
    min-height: 380px;
  }
  
  .top {
    flex: 0 0 220px;
  }
}

@media (max-width: 480px) {
  .cards {
    grid-template-columns: 1fr;
    padding: 20px 10px;
  }
  
  .card {
    max-width: 100%;
  }
}


.intro {
    color: #fff;
    padding: 70px 20px;
    box-shadow: 0 10px 30px rgba(103, 121, 100, 0.3);
    background-image: url('../img/f.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    position: relative;
    min-height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
}


.intro-content {
    max-width: 650px;
    margin: 0 auto;
    text-align: center;
    position: relative;
    z-index: 2;
    padding: 25px;
    color: #2e2a21de;
    border-radius: 15px;
    background: rgba(255, 255, 255, 0.1);

}

.intro h1 {
    font-size: 42px;
    margin-bottom: 15px;

    line-height: 1.2;
}

.intro p {
    font-size: 20px;
    line-height: 1.6;

    max-width: 500px;
    margin: 0 auto;
}

/* Десктопы */
@media (max-width: 1200px) {
    .intro {
        min-height: 450px;
        padding: 70px 20px;
    }
    
    .intro h1 {
        font-size: 42px;
    }
    
    .intro p {
        font-size: 20px;
    }
}

/* Планшеты */
@media (max-width: 992px) {
    .intro {
        min-height: 400px;
        padding: 60px 20px;
    }
    
    .intro-content {
        max-width: 600px;
    }
    
    .intro h1 {
        font-size: 36px;
    }
    
    .intro p {
        font-size: 18px;
        max-width: 450px;
    }
}

/* Маленькие планшеты */
@media (max-width: 768px) {
    .intro {
        min-height: 350px;
        padding: 50px 15px;
    }
    
    .intro-content {
        max-width: 550px;
        padding: 20px;
    }
    
    .intro h1 {
        font-size: 30px;
        margin-bottom: 12px;
    }
    
    .intro p {
        font-size: 16px;
        line-height: 1.5;
        max-width: 400px;
    }
}

/* Мобильные устройства */
@media (max-width: 576px) {
    .intro {
        min-height: 300px;
        padding: 40px 10px;
    }
    
    .intro-content {
        max-width: 450px;
        padding: 15px;
        width: 95%;
    }
    
    .intro h1 {
        font-size: 24px;
        margin-bottom: 10px;
    }
    
    .intro p {
        font-size: 14px;
        line-height: 1.4;
        max-width: 350px;
    }
}

/* Маленькие мобильные */
@media (max-width: 375px) {
    .intro {
        min-height: 250px;
        padding: 30px 10px;
    }
    
    .intro-content {
        max-width: 350px;
        padding: 12px;
    }
    
    .intro h1 {
        font-size: 20px;
        margin-bottom: 8px;
    }
    
    .intro p {
        font-size: 13px;
        line-height: 1.3;
        max-width: 300px;
    }
}

/* Альбомная ориентация на мобильных */
@media (max-width: 768px) and (orientation: landscape) {
    .intro {
        min-height: 280px;
        padding: 40px 20px;
    }
    
    .intro h1 {
        font-size: 28px;
    }
    
    .intro p {
        font-size: 16px;
    }
}

/* Высокие экраны */
@media (min-height: 800px) {
    .intro {
        min-height: 500px;
        padding: 80px 20px;
    }
}

/* Ультраширокие экраны */
@media (min-width: 1600px) {
    .intro-content {
        max-width: 700px;
    }
    
    .intro h1 {
        font-size: 48px;
    }
    
    .intro p {
        font-size: 22px;
        max-width: 600px;
    }
}