/**
 * MG Mega Menu 2 Styles
 *
 * @package MG_Mega_Menu_2
 */

/* ==================== CONTAINER ==================== */

.mgmm2-content {
    width: 100%;
    background-color: #ffffff;
}

.mgmm2-content * {
    box-sizing: border-box;
}

.mgmm2-inner {
    display: flex;
    gap: 40px;
    align-items: stretch;
}

/* ==================== COLUMNS ==================== */

.mgmm2-columns {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 40px;
    flex: 1;
    min-width: 0;
}

.mgmm2-column {
    min-width: 0;
}

/* ==================== COLUMN TITLE ==================== */

.mgmm2-col-title {
    font-size: 14px;
    font-weight: 700;
    color: #0a4a5c;
    text-transform: uppercase;
    margin-bottom: 15px;
    letter-spacing: 0.5px;
    min-height: 1.5em;
}

/* ==================== COLUMN ITEMS ==================== */

.mgmm2-col-item {
    margin-bottom: 8px;
}

.mgmm2-col-item:last-child {
    margin-bottom: 0;
}

.mgmm2-col-item a {
    color: #333333;
    text-decoration: none;
    font-size: 14px;
    line-height: 1.5;
    transition: color 0.3s ease, text-decoration 0.3s ease;
    display: block;
}

.mgmm2-col-item a:hover {
    color: #0a4a5c;
    text-decoration: underline;
}

/* ==================== FEATURED IMAGE ==================== */

.mgmm2-featured-image {
    flex-shrink: 0;
    width: 300px;
    display: flex;
    align-items: center;
}

.mgmm2-featured-image a {
    display: block;
    width: 100%;
}

.mgmm2-featured-image img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: contain;
}

/* ==================== RESPONSIVE ==================== */

@media (max-width: 1200px) {
    .mgmm2-inner {
        gap: 30px;
    }

    .mgmm2-columns {
        gap: 30px;
    }

    .mgmm2-featured-image {
        width: 250px;
    }
}

@media (max-width: 1024px) {
    .mgmm2-columns {
        grid-template-columns: repeat(2, 1fr);
        gap: 25px;
    }

    .mgmm2-inner {
        flex-direction: column;
    }

    .mgmm2-featured-image {
        width: 100%;
        max-width: 400px;
    }
}

@media (max-width: 767px) {
    .mgmm2-columns {
        display: block;
    }

    .mgmm2-column {
        padding-bottom: 0;
        border-bottom: none;
    }

    /* 隱藏空欄位 */
    .mgmm2-column-empty {
        display: none;
    }

    /* 隱藏標題 */
    .mgmm2-col-title {
        display: none;
    }

    /* 項目間距一致 */
    .mgmm2-col-item {
        margin-bottom: 0;
    }

    .mgmm2-col-item a {
        font-size: 14px;
        padding: 8px 0;
    }

    /* 隱藏圖片 */
    .mgmm2-featured-image {
        display: none;
    }
}
