.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 15px;
}

.search-section {
    display: flex;
    align-items: center;
    gap: 40px;
    margin-bottom: 60px;
    max-width: 1200px;
    min-height: 500px;
    justify-content: space-between;
    padding: 35px;
    background: linear-gradient(140deg, #fbfcf3 0%, #ffffff 50%, #f1fff7 100%);
    border-radius: 24px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.06);
    position: relative;
    overflow: hidden;
}

.search-section::before {
    content: '';
    position: absolute;
    top: -20%;
    right: -10%;
    width: 400px;
    height: 400px;
    border-radius: 50%;
    pointer-events: none;
}

.search-section::after {
    content: '';
    position: absolute;
    bottom: -30%;
    left: -5%;
    width: 300px;
    height: 300px;
    border-radius: 50%;
    pointer-events: none;
}

.search-form {
    margin-top: 30px;
    display: flex;
    gap: 12px;
    align-items: stretch;
    max-width: 450px;
    height: 56px;
    position: relative;
}

.search-form input[type="text"] {
    padding: 16px 20px;
    border-radius: 16px;
    border: 2px solid #e2e8f0;
    flex: 1;
    font-size: 16px;
    box-sizing: border-box;
    margin: 0;
    outline: none;
    background: white;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.04);
    transition: all 0.3s ease;
}

.search-form input[type="text"]::placeholder {
    color: #a0aec0;
}

.search-form button {
    padding: 16px 32px;
    border-radius: 16px;
    border: none;
    background: linear-gradient(135deg, var(--green) 0%, #0da558 100%);
    color: white;
    cursor: pointer;
    font-size: 16px;
    font-weight: 600;
    white-space: nowrap;
    transition: all 0.3s ease;
    margin: 0;
    box-shadow: 0 4px 10px var(--green);
}

.search-form button:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px var(--green);
}

.search-form button:active {
    transform: translateY(0);
}

.search-section p {
    max-width: 500px;
    font-size: 20px;
    margin-top: 15px;
    color: var(--text-secondary);
    line-height: 1.6;
}

.search-section h1 {
    font-size: 42px;
    font-weight: 600;
    line-height: 1.2;
    margin-bottom: 10px;
}

.search-section .search-section-img {
    width: 45%;
    max-width: 500px;
    height: auto;
    border-radius: 10px;
    flex-shrink: 0;
}

.search-section .search-section-img img {
    width: 100%;
    height: auto;
    object-fit: contain;
    max-height: 420px;
}

.categories {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
  transition: 0.22s;
}


.category-card {
  position: relative;
  border-radius: 50px;
  overflow: hidden;
  transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.category-card:hover {
    transform: translateY(-4px) scale(1.02);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.category-card:hover img {
    transform: scale(1.05);
}

.category-card img {
    transition: transform 0.3s ease;
}

.category-card img {
  width: 102%;
  height: 102%;
  object-fit: cover;
  transform: scale(1.02);
  transform-origin: center;
  transition: transform 0.3s ease;
}

.label {
  position: absolute;
  bottom: 15px;
  left: 15px;
  padding: 10px 20px;
  background: white;
  border-radius: 25px;
  font-size: 16px;
  font-weight: 600;
  box-shadow: 0 4px 15px rgba(0,0,0,0.15);
  white-space: nowrap;
  transition: all 0.3s ease;
  color: var(--text-primary);
}

.category-card:hover .label {
  background: var(--green);
  color: white;
  transform: translateY(-2px);
}

.container-how-it-works {
    margin: 0 auto;
    text-align: center;
    margin-top: 150px;
    display: flex;
    flex-direction: column;
    align-items: center;
    max-width: 1200px;
    height: auto;
    background-color: white;
    padding: 15px;
    box-sizing: border-box;
}

.container-how-it-works .steps {
    margin-top: 50px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    
}

.container-how-it-works .step-image {
    max-width: 100%;
    height: auto;
    flex-shrink: 1;
    object-fit: contain;
    transition: all 0.3s ease;
}

.container-how-it-works .step-arrow {
    width: 85px;
    height: 85px;
    margin-top: 180px;
    flex-shrink: 0;
}

.how-it-works-title {
    width: 100%;
    margin: 0px;
    padding: 20px 0;
    justify-content: center;
}

/* Планшеты (768px - 1024px) */
@media screen and (max-width: 1200px) {
    .container-how-it-works {
        margin-top: 100px;
        padding: 15px;
    }
    .container-how-it-works .steps{
        flex-wrap: wrap;

    }
    .container-how-it-works .step-arrow {
        display: none;
    }
    
    .container-how-it-works .steps {
        margin-top: 30px;
    }
}

@media screen and (max-width: 1030px){
    #img-step3{
        margin: 0 auto;
    }

}

/* Мобильные устройства (480px - 767px) */
@media screen and (max-width: 767px) {
    .container-how-it-works {
        margin-top: 80px;
        padding: 10px;
    }
    .container-how-it-works .step-arrow {
        display: block;
    }
    
    #img-step3{
        margin: 0 auto;
    }
    
    .container-how-it-works .steps {
        flex-direction: column;
        margin-top: 20px;
    }
    
    .container-how-it-works .step-arrow {
        width: 40px;
        height: 40px;
        margin-top: 20px;
        margin-bottom: 20px;
        transform: rotate(90deg); /* Поворачиваем стрелку для вертикального расположения */
    }
    
    .container-how-it-works .step-image {
        max-width: 80%;
        margin: 10px 0;
    }
    
    .how-it-works-title {
        padding: 15px 0;
        font-size: 1.5em;
    }

    .search-section .search-section-img{
        display: none;
    }
    
    /* Предотвращаем zoom на iOS */
    .search-form input[type="text"] {
        font-size: 16px !important;
    }
}

/* Маленькие мобильные устройства (до 479px) */
@media screen and (max-width: 479px) {
    .container-how-it-works {
        margin-top: 60px;
        padding: 5px;
    }
    
    .container-how-it-works .step-arrow {
        width: 30px;
        height: 30px;
        margin-top: 15px;
        margin-bottom: 15px;
    }
    
    .container-how-it-works .step-image {
        max-width: 90%;
    }
    
    .how-it-works-title {
        font-size: 1.3em;
        padding: 10px 0;
    }
}

/* Большие экраны (более 1200px) */
@media screen and (min-width: 1201px) {
    .container-how-it-works {
        margin: 150px auto 0;
    }
}

@media (max-width:900px){
    #main-tools-bg{
        width: 400px;
    }
}






/* Эффекты для поисковой секции */
.search-section input[type="text"] {
  transition: all 0.3s ease;
  border: 2px solid #e2e8f0;
}

.search-section input[type="text"]:focus {
  border-color: var(--green);
  box-shadow: 0 0 0 3px rgba(16, 195, 108, 0.1);
  outline: none;
}

.search-section button {
  transition: all 0.3s ease;
}

.search-section button:hover {
  transform: translateY(-1px);
  box-shadow: 0 3px 10px rgba(16, 195, 108, 0.3);
}



.category-card a {
  display: block;
  width: 100%;
  height: 100%;
  line-height: 0;
}
/* Fix category card images */
.category-card,
.category-card a,
.category-card img {
  border-radius: 24px !important;
}

.category-card {
  padding: 0 !important;
  background: transparent !important;
}

.category-card a {
  display: block;
  line-height: 0;
}

.category-card img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
}

/* ==================== HOW IT WORKS - NEW DESIGN ==================== */
.how-it-works {
    margin: 60px auto 80px;
    padding: 50px 40px;
    background: linear-gradient(140deg, #fbfcf3 0%, #ffffff 50%, #f1fff7 100%);
    border-radius: 24px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.06);
    position: relative;
    overflow: hidden;
}

.how-it-works::before {
    content: '';
    position: absolute;
    top: -20%;
    right: -10%;
    width: 400px;
    height: 400px;
    border-radius: 50%;
    pointer-events: none;
}

.how-it-works::after {
    content: '';
    position: absolute;
    bottom: -30%;
    left: -5%;
    width: 300px;
    height: 300px;
    border-radius: 50%;
    pointer-events: none;
}

.how-it-works-header {
    text-align: center;
    margin-bottom: 60px;
    position: relative;
    z-index: 1;
}

.how-it-works-header h2 {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 12px;
    background: linear-gradient(135deg, var(--green) 0%, #0a9e4f 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.how-it-works-header p {
    font-size: 1.15rem;
    color: var(--text-secondary);
    max-width: 500px;
    margin: 0 auto;
}

.steps-container {
    display: flex;
    align-items: stretch;
    justify-content: center;
    gap: 20px;
    position: relative;
    z-index: 1;
}

.step-card {
    flex: 1;
    max-width: 320px;
    background: white;
    border-radius: 24px;
    padding: 40px 30px;
    text-align: center;
    position: relative;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.06);
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    display: flex;
    flex-direction: column;
}

.step-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 50px rgba(16, 195, 108, 0.15);
}

.step-number {
    position: absolute;
    top: -18px;
    left: 50%;
    transform: translateX(-50%);
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, var(--green) 0%, var(--yellow) 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    font-weight: 700;
    color: white;
    box-shadow: 0 4px 15px rgba(16, 195, 108, 0.3);
}

.step-icon {
    width: 80px;
    height: 80px;
    margin: 10px auto 25px;
    background: linear-gradient(135deg, rgba(16, 195, 108, 0.1) 0%, rgba(250, 204, 21, 0.1) 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.step-card:hover .step-icon {
    background: linear-gradient(135deg, rgba(16, 195, 108, 0.2) 0%, rgba(250, 204, 21, 0.2) 100%);
    transform: scale(1.05);
}

.step-icon i {
    font-size: 2rem;
    background: linear-gradient(135deg, var(--green) 0%, #0da558 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.step-card h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 12px;
}

.step-card p {
    font-size: 0.95rem;
    color: var(--text-secondary);
    line-height: 1.6;
    margin: 0;
    flex-grow: 1;
}

.step-connector {
    display: flex;
    align-items: center;
    align-self: center;
    justify-content: center;
    color: var(--green);
    opacity: 0.5;
    flex-shrink: 0;
}

.step-connector .connector-line {
    width: 30px;
    height: 2px;
    background: linear-gradient(90deg, var(--green), var(--yellow));
    margin-right: 5px;
}

.step-connector i {
    font-size: 1rem;
}

.how-it-works-cta {
    text-align: center;
    margin-top: 50px;
    position: relative;
    z-index: 1;
}

.how-it-works-cta .cta-button {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    padding: 16px 36px;
    background: linear-gradient(135deg, var(--green) 0%, #0da558 100%);
    color: white;
    text-decoration: none;
    border-radius: 50px;
    font-size: 1.1rem;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 4px 20px rgba(16, 195, 108, 0.3);
}

.how-it-works-cta .cta-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 30px rgba(16, 195, 108, 0.4);
}

.how-it-works-cta .cta-button i {
    transition: transform 0.3s ease;
}

.how-it-works-cta .cta-button:hover i {
    transform: translateX(4px);
}

/* How It Works - Responsive */
@media screen and (max-width: 900px) {
    .how-it-works {
        margin: 60px auto 60px;
        padding: 50px 25px;
    }
    
    .steps-container {
        flex-direction: column;
        align-items: center;
        gap: 40px;
    }
    
    .step-card {
        max-width: 100%;
        width: 100%;
    }
    
    .step-connector {
        padding-top: 0;
        transform: rotate(90deg);
    }
    
    .how-it-works-header h2 {
        font-size: 2rem;
    }
}

@media screen and (max-width: 480px) {
    .how-it-works {
        margin: 40px auto;
        padding: 40px 20px;
        border-radius: 24px;
    }
    
    .how-it-works-header h2 {
        font-size: 1.6rem;
    }
    
    .how-it-works-header p {
        font-size: 1rem;
    }
    
    .step-card {
        padding: 35px 20px;
    }
    
    .step-icon {
        width: 70px;
        height: 70px;
    }
    
    .step-icon i {
        font-size: 1.7rem;
    }
    
    .how-it-works-cta .cta-button {
        padding: 14px 28px;
        font-size: 1rem;
    }
    
    /* Предотвращаем zoom на iOS */
    .search-form input[type="text"] {
        font-size: 16px !important;
    }
}
