/* JobSure Enhanced Job Cards CSS */

/* Card container styling */
.job-card {
    border-radius: 10px;
    overflow: hidden;
    transition: all 0.4s ease;
    border: 1px solid rgba(0, 0, 0, 0.08);
    background-color: #fff;
    height: 100%;
    position: relative;
    display: flex;
    flex-direction: column;
}

.job-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
    border-color: rgba(52, 152, 219, 0.3);
}

/* Card image styling */
.job-card .card-img-top {
    transition: all 0.5s ease;
    height: 180px;
    object-fit: cover;
    width: 100%;
}

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

.job-card .card-img-container {
    overflow: hidden;
    position: relative;
}

/* Ribbon badges */
.ribbon-wrapper {
    width: 85px;
    height: 88px;
    overflow: hidden;
    position: absolute;
    top: -3px;
    right: -3px;
    z-index: 10;
}

.ribbon {
    font-size: 12px;
    font-weight: bold;
    color: #fff;
    text-align: center;
    transform: rotate(45deg);
    position: relative;
    padding: 7px 0;
    left: -5px;
    top: 15px;
    width: 120px;
    box-shadow: 0px 0px 3px rgba(0,0,0,0.3);
}

.ribbon:before, .ribbon:after {
    content: "";
    border-top: 3px solid transparent;
    border-left: 3px solid transparent;
    border-right: 3px solid transparent;
    position: absolute;
    bottom: -3px;
}

.ribbon:before {
    left: 0;
}

.ribbon:after {
    right: 0;
}

.ribbon.featured {
    background: linear-gradient(135deg, #f39c12, #e74c3c);
}

.ribbon.top-view {
    background: linear-gradient(135deg, #3498db, #2980b9);
}

.ribbon.recommended {
    background: linear-gradient(135deg, #2ecc71, #27ae60);
}

/* Hide old badge styles */
.featured-badge, .top-view-badge, .recommended-badge, .clicks-badge {
    display: none;
}

/* Page type badge */
.page-type-badge {
    position: absolute;
    top: 15px;
    left: 15px;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.2);
    z-index: 2;
    color: white;
}

/* Page type icon at bottom right of image */
.page-type-icon {
    position: absolute;
    bottom: 10px;
    right: 10px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1rem;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.2);
    z-index: 2;
    transition: all 0.3s ease;
}

.page-type-icon:hover {
    transform: scale(1.1);
}

/* Different page type styles */
.page-type-badge.survey, 
.page-type-badge:has(i.fa-poll),
.page-type-icon.survey {
    background: linear-gradient(135deg, #9b59b6, #8e44ad);
}

.page-type-badge.remote, 
.page-type-badge:has(i.fa-laptop-house),
.page-type-icon.remote {
    background: linear-gradient(135deg, #27ae60, #2ecc71);
}

.page-type-badge.course, 
.page-type-badge:has(i.fa-graduation-cap),
.page-type-icon.course {
    background: linear-gradient(135deg, #3498db, #2980b9);
}

.page-type-badge.finance, 
.page-type-badge:has(i.fa-money-bill-wave),
.page-type-icon.finance {
    background: linear-gradient(135deg, #16a085, #1abc9c);
}

.page-type-badge.default, 
.page-type-badge:has(i.fa-briefcase),
.page-type-icon.default {
    background: linear-gradient(135deg, #7f8c8d, #95a5a6);
}

@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(231, 76, 60, 0.4);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(231, 76, 60, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(231, 76, 60, 0);
    }
}

/* Card body styling for equal height */
.job-card .card-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    padding: 1.25rem;
}

/* Card title with fixed height to maintain consistency */
.job-card .card-title {
    margin-bottom: 0.75rem;
    font-size: 1.1rem;
    font-weight: 600;
    line-height: 1.4;
    height: 3.1rem;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    line-clamp: 2;
}

/* Card text with fixed height */
.job-card .card-text {
    margin-bottom: 1rem;
    height: 4.5rem;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    line-clamp: 3;
}

/* Category badge */
.job-card .category-badge {
    display: inline-block;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    background-color: rgba(52, 152, 219, 0.1);
    color: #3498db;
    margin-bottom: 10px;
    transition: all 0.3s ease;
}

.job-card:hover .category-badge {
    background-color: #3498db;
    color: white;
}

/* Job details */
.job-details {
    display: flex;
    flex-wrap: wrap;
    margin-bottom: 15px;
    gap: 10px;
}

.job-detail-item {
    display: flex;
    align-items: center;
    font-size: 0.85rem;
    color: #7f8c8d;
    margin-right: 15px;
}

.job-detail-item i {
    color: #3498db;
    margin-right: 5px;
    font-size: 0.9rem;
}

/* Button styling */
.job-card .btn-view-details {
    background: linear-gradient(to right, #3498db, #2980b9);
    color: white;
    border: none;
    border-radius: 5px;
    padding: 10px 20px;
    font-weight: 600;
    transition: all 0.3s ease;
    text-align: center;
    text-decoration: none;
    display: block;
    width: 100%;
    position: relative;
    overflow: hidden;
    z-index: 1;
    margin-top: auto;
}

.job-card .btn-view-details:before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(to right, #2980b9, #3498db);
    transition: all 0.4s ease;
    z-index: -1;
}

.job-card .btn-view-details:hover:before {
    left: 0;
}

.job-card .btn-view-details:hover {
    box-shadow: 0 5px 15px rgba(52, 152, 219, 0.4);
    transform: translateY(-2px);
}

/* Responsive adjustments */
@media (max-width: 767.98px) {
    .job-card {
        margin-bottom: 20px;
    }
}
