.home-modules {
    width: 100%;
    height: 300px;
    background: transparent;
    margin-top: -150px;
    position: relative;
    z-index: 2;
}

.hm-inner {
    width: 90%;
    max-width: 1440px;
    height: 100%;
    margin: 0 auto;
    display: flex;
    align-items: stretch;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 30px 60px -12px rgba(26, 86, 219, 0.28), 0 18px 36px -18px rgba(15, 23, 42, 0.25);
}

.hm-card {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    color: #333;
    text-decoration: none;
    position: relative;
    background: #fff;
    transition: background 0.3s;
}

.hm-card+.hm-card::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 1px;
    height: 56%;
    background: #e8ebf0;
    z-index: 2;
}

.hm-card::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(160deg, var(--color1), #0d3fa8);
    opacity: 0;
    transition: opacity 0.3s;
    z-index: 1;
}

.hm-card:hover {
    background: var(--color1);
}

.hm-card:hover::after {
    opacity: 1;
}

.hm-icon {
    flex-shrink: 0;
    width: 100%;
    height: 130px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    z-index: 3;
    transition: transform 0.4s ease;
}

.hm-icon svg {
    width: 52px;
    height: 52px;
}

.hm-card:hover .hm-icon {
    transform: translateY(-100%);
}

.hm-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-width: 0;
    padding: 0 24px;
    text-align: center;
    position: relative;
    z-index: 3;
    transition: transform 0.4s ease;
}

.hm-card:hover .hm-info {
    transform: translateY(-130px);
}

.hm-title {
    font-size: 20px;
    font-weight: 700;
    color: var(--color1);
    letter-spacing: 1px;
    transition: color 0.3s;
}

.hm-title::after {
    content: '';
    display: block;
    width: 28px;
    height: 2px;
    border-radius: 2px;
    margin: 10px auto 0;
    background: linear-gradient(90deg, var(--color1), rgba(26, 86, 219, 0.15));
    transition: background 0.3s;
}

.hm-card:hover .hm-title::after {
    background: linear-gradient(90deg, #fff, rgba(255, 255, 255, 0.25));
}

.hm-desc {
    font-size: 13px;
    line-height: 1.7;
    color: #6b7280;
    transition: color 0.3s;
}

.hm-card:hover .hm-title,
.hm-card:hover .hm-desc {
    color: #fff;
}

@media (max-width: 900px) {
    .home-modules {
        height: auto;
        margin-top: -100px;
    }

    .hm-inner {
        width: 90%;
        max-width: 1440px;
        height: auto;
        display: grid;
        grid-template-columns: 1fr 1fr;
        grid-auto-rows: auto;
        border-radius: 16px;
        overflow: hidden;
        box-shadow: 0 24px 50px -18px rgba(26, 86, 219, 0.25), 0 14px 28px -18px rgba(15, 23, 42, 0.2);
    }

    .hm-card {
        flex-direction: column;
        align-items: stretch;
        padding: 0;
        background: #fff;
    }

    .hm-card::after {
        display: none;
    }

    .hm-card:hover,
    .hm-card:active {
        background: #fff;
    }

    .hm-card:hover .hm-icon,
    .hm-card:hover .hm-info {
        transform: none;
    }

    .hm-card:hover .hm-title {
        color: var(--color1);
    }

    .hm-card:hover .hm-title::after {
        background: linear-gradient(90deg, var(--color1), rgba(26, 86, 219, 0.15));
    }

    .hm-card:hover .hm-desc {
        color: #6b7280;
    }

    .hm-card+.hm-card::before {
        display: none;
    }

    .hm-card:nth-child(even)::before {
        display: block;
    }

    .hm-icon {
        flex-shrink: 0;
        width: 100%;
        height: 110px;
        border-radius: 0;
    }

    .hm-icon svg {
        width: 36px;
        height: 36px;
    }

    .hm-info {
        align-items: center;
        justify-content: center;
        text-align: center;
        gap: 8px;
        padding: 16px 12px 20px;
    }

    .hm-title {
        font-size: 16px;
        color: var(--color1);
    }

    .hm-desc {
        font-size: 12px;
        line-height: 1.6;
    }
}
