/*
 Theme Name: BuddyBoss Child
 Template: buddyboss-theme
*/


/*CSS PARA BUSQUEDA*/
/* Diseño horizontal tipo dos columnas */
.bb-curso-search-card.two-column-layout {
    display: flex;
    flex-direction: row;
    align-items: stretch;
    border: 1px solid #ddd;
    border-radius: 10px;
    overflow: hidden;
    background-color: #fff;
    margin-bottom: 1.5rem;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
    transition: transform 0.2s ease-in-out;
}

.bb-curso-search-card.two-column-layout:hover {
    transform: scale(1.01);
}

.bb-curso-search-link {
    display: flex;
    flex-direction: row;
    width: 100%;
    text-decoration: none;
    color: inherit;
}

.bb-curso-search-body {
    flex: 1 1 60%;
    padding: 1.2rem;
    display: flex;
    align-items: center;
    justify-content: flex-start;
}

.bb-curso-search-title {
    font-size: 1.3rem;
    font-weight: 600;
    margin: 0;
    color: #333;
}

.bb-curso-search-thumb-wrapper {
    flex: 1 1 40%;
    min-width: 200px;
    max-width: 300px;
    background-color: #f4f4f4;
    display: flex;
    align-items: center;
    justify-content: center;
}

.bb-curso-search-thumb-img {
    width: 100%;
    height: auto;
    object-fit: cover;
}

.bb-curso-search-thumb-placeholder {
    height: 100%;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #999;
    font-size: 1rem;
    font-weight: bold;
    background-color: #e0e0e0;
}

/* Responsive */
@media (max-width: 768px) {
    .bb-curso-search-card.two-column-layout,
    .bb-curso-search-link {
        flex-direction: column;
    }

    .bb-curso-search-thumb-wrapper {
        max-width: 100%;
    }
}

/* ==========================================================================
   CERTIFICADOS BUDDYBOSS - CSS PERSONALIZADO
   ========================================================================== */

/* Header con estadísticas */
.bb-certificates-header {
	background: linear-gradient(135deg, #116323, #1a7a2e) !important;
	color: white !important;
	padding: 2rem !important;
	border-radius: 12px !important;
	margin-bottom: 2rem !important;
	text-align: center !important;
	position: relative !important;
	overflow: hidden !important;
}

.bb-certificates-header h2 {
	color: white !important;
	margin: 0 0 1rem 0 !important;
	font-size: 1.8rem !important;
	font-weight: 700 !important;
}

.bb-certificates-header::before {
	content: '' !important;
	position: absolute !important;
	top: 0 !important;
	left: 0 !important;
	right: 0 !important;
	bottom: 0 !important;
	background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grain" width="100" height="100" patternUnits="userSpaceOnUse"><circle cx="50" cy="50" r="1" fill="rgba(255,255,255,0.1)"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>') !important;
	opacity: 0.3 !important;
}

.bb-certificates-header > * {
	position: relative !important;
	z-index: 1 !important;
}

.bb-certificates-stats {
	display: flex !important;
	justify-content: center !important;
	align-items: center !important;
	gap: 1rem !important;
	margin-top: 1rem !important;
}

.bb-cert-count {
	background: rgba(255, 255, 255, 0.2) !important;
	padding: 0.5rem 1rem !important;
	border-radius: 20px !important;
	font-weight: 600 !important;
	backdrop-filter: blur(10px) !important;
}

/* Animaciones sutiles */
@keyframes fadeInUp {
	from {
		opacity: 0;
		transform: translateY(20px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

@keyframes hoverGlow {
	0%, 100% {
		box-shadow: 0 4px 15px rgba(17, 99, 35, 0.15);
	}
	50% {
		box-shadow: 0 8px 25px rgba(17, 99, 35, 0.25);
	}
}

/* Contenedor principal */
#bb-learndash-profile {
	padding: 1.5rem 0 !important;
}

/* Grid de certificados */
#bb-learndash-profile #certificate_list {
	display: grid !important;
	grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)) !important;
	gap: 1.5rem !important;
	list-style: none !important;
	margin: 0 !important;
	padding: 0 !important;
}

/* Elementos de lista con animación sutil */
#bb-learndash-profile #certificate_list li {
	animation: fadeInUp 0.6s ease-out !important;
	animation-fill-mode: both !important;
}

#bb-learndash-profile #certificate_list li:nth-child(1) { animation-delay: 0.1s !important; }
#bb-learndash-profile #certificate_list li:nth-child(2) { animation-delay: 0.2s !important; }
#bb-learndash-profile #certificate_list li:nth-child(3) { animation-delay: 0.3s !important; }
#bb-learndash-profile #certificate_list li:nth-child(4) { animation-delay: 0.4s !important; }
#bb-learndash-profile #certificate_list li:nth-child(5) { animation-delay: 0.5s !important; }
#bb-learndash-profile #certificate_list li:nth-child(6) { animation-delay: 0.6s !important; }

/* Tarjetas de certificados */
#bb-learndash-profile .bb-certificate-wrap {
	background: #fff !important;
	border-radius: 12px !important;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1) !important;
	overflow: hidden !important;
	transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
	border: 1px solid #e9ecef !important;
	position: relative !important;
}

#bb-learndash-profile .bb-certificate-wrap:hover {
	transform: translateY(-4px) !important;
	box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15) !important;
}

#bb-learndash-profile .bb-certificate-wrap::before {
	content: '' !important;
	position: absolute !important;
	top: 0 !important;
	left: 0 !important;
	right: 0 !important;
	height: 4px !important;
	background: linear-gradient(90deg, #116323, #1a7a2e) !important;
}

/* Contenido de certificado */
#bb-learndash-profile .bb-certificate-content {
	padding: 1.5rem !important;
}

/* Título del certificado */
#bb-learndash-profile .bb-certificate-title {
	margin: 0 0 1rem 0 !important;
	font-size: 1.25rem !important;
	font-weight: 700 !important;
	color: #2c3e50 !important;
	line-height: 1.3 !important;
}

#bb-learndash-profile .bb-certificate-title span {
	font-size: 0.9rem !important;
	color: #6c757d !important;
	font-weight: 400 !important;
	display: block !important;
	margin-bottom: 0.25rem !important;
}

#bb-learndash-profile .bb-certificate-title a {
	color: #116323 !important;
	text-decoration: none !important;
	transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

#bb-learndash-profile .bb-certificate-title a:hover {
	color: #0d4a1c !important;
	text-decoration: underline !important;
}

/* Fecha del certificado */
#bb-learndash-profile .bb-certificate-date {
	display: inline-flex !important;
	align-items: center !important;
	gap: 0.5rem !important;
	background: rgba(40, 167, 69, 0.1) !important;
	color: #28a745 !important;
	padding: 0.5rem 0.75rem !important;
	border-radius: 20px !important;
	font-size: 0.875rem !important;
	font-weight: 500 !important;
	margin-bottom: 1.5rem !important;
}

#bb-learndash-profile .bb-certificate-date::before {
	content: '✓' !important;
	font-weight: bold !important;
}

/* Botón de descarga */
#bb-learndash-profile .bb-certificate-download {
	margin: 0 !important;
}

#bb-learndash-profile .bb-certificate-download a {
	display: inline-flex !important;
	align-items: center !important;
	justify-content: center !important;
	gap: 0.5rem !important;
	background: linear-gradient(135deg, #116323, #1a7a2e) !important;
	color: #fff !important;
	padding: 0.875rem 1.5rem !important;
	border-radius: 12px !important;
	text-decoration: none !important;
	font-weight: 600 !important;
	font-size: 0.95rem !important;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1) !important;
	transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
	width: 100% !important;
	border: none !important;
	cursor: pointer !important;
}

#bb-learndash-profile .bb-certificate-download a:hover {
	background: linear-gradient(135deg, #0d4a1c, #0d4a1c) !important;
	box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15) !important;
	transform: translateY(-1px) !important;
	color: #fff !important;
}

#bb-learndash-profile .bb-certificate-download a:active {
	transform: translateY(0) !important;
}

/* Icono de descarga */
.bb-download-icon {
	width: 18px !important;
	height: 18px !important;
	transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

#bb-learndash-profile .bb-certificate-download a:hover .bb-download-icon {
	transform: translateY(2px) !important;
}

#bb-learndash-profile .bb-certificate-download a:hover i {
	transform: translateY(1px) !important;
}

/* Estado vacío mejorado */
#bb-learndash-profile .bp-feedback.bp-messages.info {
	text-align: center !important;
	padding: 3rem 2rem !important;
	background: #f8f9fa !important;
	border-radius: 12px !important;
	border: 2px dashed #e9ecef !important;
	animation: fadeInUp 0.6s ease-out !important;
}

#bb-learndash-profile .bp-feedback .bp-icon {
	font-size: 3rem !important;
	color: #6c757d !important;
	margin-bottom: 1rem !important;
	display: block !important;
}

#bb-learndash-profile .bp-feedback p {
	font-size: 1.1rem !important;
	color: #6c757d !important;
	margin: 0 !important;
}

/* Responsive Design */
@media (max-width: 1024px) {
	#bb-learndash-profile #certificate_list {
		grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)) !important;
	}
}

@media (max-width: 768px) {
	.bb-certificates-header {
		padding: 1.5rem !important;
	}
	
	.bb-certificates-stats {
		flex-direction: column !important;
		gap: 0.5rem !important;
	}
	
	#bb-learndash-profile #certificate_list {
		grid-template-columns: 1fr !important;
		gap: 1rem !important;
	}
	
	#bb-learndash-profile .bb-certificate-content {
		padding: 1.25rem !important;
	}
}

@media (max-width: 480px) {
	#bb-learndash-profile {
		padding: 1rem 0 !important;
	}
	
	.bb-certificates-header {
		margin: 0 -1rem 1.5rem -1rem !important;
		border-radius: 0 !important;
	}
	
	#bb-learndash-profile .bb-certificate-wrap {
		border-radius: 8px !important;
	}
}

/* Mejoras para accesibilidad */
@media (prefers-reduced-motion: reduce) {
	#bb-learndash-profile * {
		animation-duration: 0.01ms !important;
		animation-iteration-count: 1 !important;
		transition-duration: 0.01ms !important;
	}
}
