/* Estilos para el sistema de banners - Vista pública */

/* Colores corporativos */
:root {
    --primary-color: #000C4F;
    --primary-hover: #001a7a;
    --success-color: #28a745;
    --warning-color: #ffc107;
    --light-gray: #f8f9fa;
    --border-color: #dee2e6;
}

/* Banner item en listado de empleos */
.banner-item {
    margin-bottom: 1rem;
}

.banner-card {
    border: 0;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
    border-left: 4px solid var(--primary-color);
    transition: all 0.2s ease-in-out;
}

.banner-card:hover {
    box-shadow: 0 0.25rem 0.5rem rgba(0, 0, 0, 0.15);
    transform: translateY(-1px);
}

.banner-link {
    text-decoration: none;
    color: inherit;
}

.banner-link:hover {
    text-decoration: none;
    color: inherit;
}

/* Contenido del banner */
.banner-title {
    margin-bottom: 0.25rem;
    font-weight: bold;
    color: var(--primary-color);
    font-size: 1rem;
}

.banner-description {
    margin-bottom: 0;
    color: #6c757d;
    font-size: 0.875rem;
    line-height: 1.4;
}

.banner-ad-indicator {
    color: #6c757d;
    font-size: 0.75rem;
}

.banner-ad-icon {
    color: var(--primary-color);
    margin-right: 0.25rem;
}

/* Imagen del banner */
.banner-image {
    max-height: 60px;
    object-fit: cover;
    border-radius: 0.375rem;
    transition: transform 0.2s ease-in-out;
}

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

/* Responsive design */
@media (max-width: 768px) {
    .banner-image {
        max-height: 50px;
    }
    
    .banner-title {
        font-size: 0.9rem;
    }
    
    .banner-description {
        font-size: 0.8rem;
    }
}

/* Estados del banner */
.banner-item[data-impression-tracked="true"] {
    position: relative;
}

.banner-item[data-impression-tracked="true"]::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 8px;
    height: 8px;
    background-color: var(--success-color);
    border-radius: 50%;
    opacity: 0.7;
    display: none; /* Solo para debug, normalmente oculto */
}

/* Animaciones */
@keyframes bannerFadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.banner-item {
    animation: bannerFadeIn 0.3s ease-in-out;
}

/* Loading state */
.banner-loading {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
}

@keyframes loading {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}

/* Error state */
.banner-error {
    border-left-color: #dc3545;
    opacity: 0.7;
}

.banner-error .banner-title {
    color: #dc3545;
}

/* Accesibilidad */
.banner-link:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

/* Print styles */
@media print {
    .banner-item {
        display: none;
    }
}