/* Job Search Advertisement Styles - Based on ZoomAmerica's Native Ad System */

/* Job Ad Post Container */
.job-ad-post {
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    margin-bottom: 20px;
    overflow: hidden;
    transition: box-shadow 0.2s ease;
}

.job-ad-post:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

/* Sponsored Label */
.job-ad-label {
    display: inline-flex;
    align-items: center;
    padding: 4px 12px;
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
    border-radius: 20px;
    font-size: 13px;
    color: #92400e;
    font-weight: 500;
    margin-bottom: 12px;
}

.job-ad-label i {
    margin-right: 6px;
    font-size: 12px;
}

/* Ad Header */
.job-ad-header {
    padding: 16px 20px 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.job-ad-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.job-ad-action-btn {
    background: none;
    border: none;
    color: #6b7280;
    padding: 4px;
    border-radius: 4px;
    transition: all 0.2s ease;
    cursor: pointer;
}

.job-ad-action-btn:hover {
    background: #f3f4f6;
    color: #374151;
}

/* Ad Content */
.job-ad-content {
    cursor: pointer;
    padding: 0 20px 20px 20px;
}

.job-ad-image {
    width: 100%;
    max-height: 200px;
    overflow: hidden;
    background: #f9fafb;
    border-radius: 8px;
    margin-bottom: 16px;
}

.job-ad-image img {
    width: 100%;
    height: auto;
    object-fit: cover;
}

.job-ad-body {
    padding: 0;
}

.job-ad-title {
    font-size: 18px;
    font-weight: 600;
    color: #111827;
    margin: 0 0 8px 0;
    line-height: 1.4;
}

.job-ad-company {
    font-size: 14px;
    color: var(--primary-color);
    font-weight: 500;
    margin-bottom: 8px;
}

.job-ad-description {
    font-size: 14px;
    color: #4b5563;
    line-height: 1.6;
    margin: 0 0 16px 0;
}

/* Job-specific ad meta */
.job-ad-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 16px;
    font-size: 13px;
    color: #6b7280;
}

.job-ad-meta-item {
    display: flex;
    align-items: center;
    gap: 4px;
}

.job-ad-salary {
    background: #ecfdf5;
    color: #065f46;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
}

/* CTA Button */
.job-ad-cta {
    margin-top: 16px;
}

.job-ad-button {
    display: inline-flex;
    align-items: center;
    padding: 10px 20px;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: white;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.2s ease;
}

.job-ad-button:hover {
    background: linear-gradient(135deg, var(--primary-dark) 0%, #3730a3 100%);
    color: white;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(94, 91, 237, 0.3);
}

.job-ad-button i {
    font-size: 12px;
    margin-left: 8px;
}

/* Ad Footer */
.job-ad-footer {
    padding: 12px 20px;
    border-top: 1px solid #e5e7eb;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #f9fafb;
}

.job-ad-footer-actions {
    display: flex;
    gap: 16px;
}

.job-ad-footer-btn {
    background: none;
    border: none;
    color: #6b7280;
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 4px;
    cursor: pointer;
    transition: color 0.2s ease;
}

.job-ad-footer-btn:hover {
    color: var(--primary-color);
}

.job-ad-location {
    font-size: 12px;
    color: #9ca3af;
    display: flex;
    align-items: center;
    gap: 4px;
}

/* Integration with job listings */
.job-results-container .job-ad-post {
    border-left: 3px solid #fbbf24;
}

/* Responsive design */
@media (max-width: 768px) {
    .job-ad-header {
        padding: 12px 16px 0 16px;
    }

    .job-ad-content {
        padding: 0 16px 16px 16px;
    }

    .job-ad-footer {
        padding: 12px 16px;
        flex-direction: column;
        gap: 8px;
        align-items: flex-start;
    }

    .job-ad-footer-actions {
        width: 100%;
        justify-content: space-around;
    }

    .job-ad-meta {
        flex-direction: column;
        gap: 6px;
    }
}

/* Ad placement indicators */
.ad-placement-indicator {
    position: absolute;
    top: -8px;
    right: 16px;
    background: #fbbf24;
    color: white;
    font-size: 10px;
    padding: 2px 6px;
    border-radius: 4px;
    font-weight: 600;
    text-transform: uppercase;
}

/* Subtle animation for ads */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.job-ad-post {
    animation: fadeInUp 0.5s ease-out;
}

/* Ad performance tracking styles */
.job-ad-post[data-viewed="true"] {
    opacity: 0.95;
}

/* Click tracking overlay */
.job-ad-content::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
}