/* ============================================================
   MJ Hot Articles — Saraya overlay style
   ============================================================ */
.mjha-wrap {
    width: 100%;
    box-sizing: border-box;
    font-family: inherit;
    border-radius: 12px;
    overflow: hidden;
    position: relative;
    z-index: 1;
    isolation: isolate;
}

/* Header — dark colored bar */
.mjha-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    background-color: #dc2626;
}

.mjha-header-left {
    display: flex;
    align-items: center;
    gap: 8px;
}

.mjha-header-icon {
    background: rgba(255,255,255,0.2);
    padding: 6px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
}

.mjha-section-title {
    margin: 0;
    font-size: 17px;
    font-weight: 700;
    color: #fff;
    text-decoration: none;
}

a.mjha-title-link { text-decoration: none; }
a.mjha-title-link:hover .mjha-section-title { opacity: 0.85; }

.mjha-more {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 13px;
    font-weight: 500;
    color: rgba(255,255,255,0.85);
    text-decoration: none;
    transition: color 0.2s;
}
.mjha-more:hover { color: #fff; }

/* List */
.mjha-list {
    display: flex;
    flex-direction: column;
    background: #fff;
    padding: 12px;
    gap: 12px;
    position: relative;
    z-index: 1;
    overflow: hidden;
}

/* Item — full width image with overlay */
.mjha-item {
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
}

.mjha-link {
    display: block;
    text-decoration: none;
    color: inherit;
    position: relative;
}

/* Image */
.mjha-image {
    position: relative;
    width: 100%;
    height: 200px;
    overflow: hidden;
    background: #222;
}

.mjha-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.5s ease;
}

.mjha-item:hover .mjha-image img { transform: scale(1.05); }

/* Gradient overlay */
.mjha-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.82) 0%, rgba(0,0,0,0.4) 50%, transparent 100%);
    z-index: 1;
}

/* Content on top of image — sits inside .mjha-link which is relative */
.mjha-content {
    position: absolute;
    inset: 0;
    z-index: 2;
    padding: 12px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

/* Category badge — top right */
.mjha-badge {
    display: inline-block;
    align-self: flex-start;
    padding: 2px 10px;
    background: rgba(255,255,255,0.2);
    backdrop-filter: blur(4px);
    border-radius: 6px;
    color: #fff;
    font-size: 11px;
    font-weight: 600;
}

/* Bottom section */
.mjha-bottom { display: flex; flex-direction: column; gap: 8px; }

.mjha-title {
    margin: 0;
    font-size: 14px;
    font-weight: 700;
    color: #fff;
    line-height: 1.45;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    transition: color 0.2s;
}
.mjha-item:hover .mjha-title { color: #fca5a5; }

/* Meta row */
.mjha-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    color: rgba(255,255,255,0.9);
    font-size: 12px;
}

.mjha-meta-left { display: flex; align-items: center; gap: 12px; }
.mjha-views, .mjha-date { display: flex; align-items: center; gap: 4px; }

/* Arrow button */
.mjha-arrow {
    width: 26px;
    height: 26px;
    background: rgba(255,255,255,0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(4px);
    color: #fff;
    transition: background 0.2s;
    flex-shrink: 0;
}
.mjha-item:hover .mjha-arrow { background: rgba(255,255,255,0.35); }

/* Responsive */

@media (max-width: 767px) {
    .mjha-wrap { border-radius: 8px; }
    .mjha-image { height: 170px; }
    .mjha-list { padding: 8px; gap: 8px; }
    .mjha-title { font-size: 13px; }
    .mjha-header { padding: 10px 12px; }
    .mjha-section-title { font-size: 15px; }
}

@media (max-width: 480px) {
    .mjha-image { height: 150px; }
    .mjha-title { font-size: 13px; }
    .mjha-list { padding: 6px; gap: 6px; }
    .mjha-content { padding: 8px; }
    .mjha-meta { font-size: 11px; }
}

@media (max-width: 360px) {
    .mjha-image { height: 130px; }
    .mjha-title { font-size: 12px; }
}
